Timedesc.Utils
val ptime_span_of_span : Span.t -> Ptime.span option
val ptime_of_timestamp : timestamp -> Ptime.t option
val span_of_ptime_span : Ptime.span -> Span.t
Warning: Subnanosecond information is lost in this conversion
val timestamp_of_ptime : Ptime.t -> timestamp
Warning: Subnanosecond information is lost in this conversion
val human_int_of_month : month -> int
This yields the usual human readable numbering of 1 to 12 inclusive
val index_of_month : month -> int
This yields the index based numbering of 0 to 11 inclusive
val month_of_human_int : int -> month option
val month_of_index : int -> month option
val weekday_of_tm_int : int -> weekday option
val tm_int_of_weekday : weekday -> int
val weekday_of_iso_int : int -> weekday option
val iso_int_of_weekday : weekday -> int
val get_local_tz_for_arg : unit -> Time_zone.t
val abbr_string_of_weekday : weekday -> string
Warning: Following functions are direct applications of the relevant formulas with little to no error checking.
You are advised to read the source code of the following functions in date_time_utils.ml
if you intend to use them to ensure they behave as you expect.
val jd_of_date : Date.t -> int
val jd_span_of_unix_epoch : Span.t
val jd_of_iso_week_date : year:int -> week:int -> weekday:weekday -> int
val weekday_of_jd : int -> weekday
val iso_week_date_of_jd : int -> int * int * weekday