package timere

  1. Overview
  2. Docs

Module Timere.DurationSource

Sourcetype t = private {
  1. days : int;
  2. hours : int;
  3. minutes : int;
  4. seconds : int;
  5. ns : int;
}

Unsigned/scalar magnitude of a period of time

Conversion to and from Span.t is lossless, but cannot convert from negative span

Sourceval make : ?days:int -> ?hours:int -> ?minutes:int -> ?seconds:int -> ?ns:int -> unit -> t
Sourceval make_frac : ?days:float -> ?hours:float -> ?minutes:float -> ?seconds:float -> ?ns:int -> unit -> t
Sourceval zero : t
Sourceval equal : t -> t -> bool
Sourceval of_span : Span.t -> t
Sourceval to_span : t -> Span.t
Sourceval to_string : t -> string
Sourceval pp : Format.formatter -> t -> unit
Sourceval to_sexp : t -> CCSexp.t
Sourceval to_sexp_string : t -> string
Sourceval of_sexp : CCSexp.t -> (t, string) result
Sourceval of_sexp_string : string -> (t, string) result
Sourceval pp_sexp : Format.formatter -> t -> unit