module Units:sig
..end
val time : (int64 * string * 'a option) list
val kib : (int64 * string * 'a option) list
val kb : (int64 * string * 'a option) list
val format : ?maxunit:string -> (int64 * string * string option) list -> int64 -> string
format ?maxunit units quantity
Example:
# format time 2175;; \- : string = "5 hours, 51 minutes, 15 seconds" # format ~maxunit:"minute" time 2175;; \- : string = "36 minutes, 15 seconds"
Partially-apply for efficiency.
maxunit
: optional maximum unit to use in formattingunits
: data structure describing units; list of (product, name, irregular plural)