Library
Module
Module type
Parameter
Class
Class type
A week of a year.
A week of a year.
A week of a year.
Per ISO 8601 week date system, a week is attributed to the year its Thursday is in.
type js =
< n : Js_of_ocaml.Js.number Js_of_ocaml.Js.readonly_prop
; year : Js_of_ocaml.Js.number Js_of_ocaml.Js.readonly_prop >
Js_of_ocaml.Js.t
val make : year:Base.int -> Base.int -> (t, Base.string) Base.Result.t
make ~year n
is { n; year }
if it represents a valid week or a relevant error message otherwise.
days week
is the sequence of dates in week
in chronological order.
include Base.Comparable.S with type t := t
val comparator : (t, comparator_witness) Base__Comparator.comparator
module O : sig ... end
Convenience module to only pull operators.
val to_string : t -> Base.string
to_string week
is the YYYY-WW representation of week
, eg. 2022-03.
val of_string : Base.string -> (t, Base.string) Base.Result.t
of_string s
is the week represented by s
as yielded by to_string
or a relevant error message if it is invalid.