package core

  1. Overview
  2. Docs
Legend:
Library
Module
Module type
Parameter
Class
Class type
type underlying
type t = private underlying
include Bin_prot.Binable.S with type t := t
val bin_size_t : t Bin_prot__.Size.sizer
val bin_write_t : t Bin_prot__.Write.writer
val bin_read_t : t Bin_prot__.Read.reader
val __bin_read_t__ : (int -> t) Bin_prot__.Read.reader
val bin_shape_t : Bin_prot__.Shape.t
val bin_writer_t : t Bin_prot__.Type_class.writer
val bin_reader_t : t Bin_prot__.Type_class.reader
val bin_t : t Bin_prot__.Type_class.t
include Ppx_compare_lib.Comparable.S with type t := t
include Ppx_hash_lib.Hashable.S with type t := t
val hash_fold_t : t Base__Ppx_hash_lib.hash_fold
val hash : t -> Base__Ppx_hash_lib.Std.Hash.hash_value
include Typerep_lib.Typerepable.S with type t := t
val typerep_of_t : t Typerep_lib.Std_internal.Typerep.t
val typename_of_t : t Typerep_lib.Typename.t
module Span : sig ... end
module Ofday : sig ... end
module Replace_polymorphic_compare : sig ... end
include Interfaces.Robustly_comparable with type t := t
val (>=.) : t -> t -> bool
val (<=.) : t -> t -> bool
val (=.) : t -> t -> bool
val (>.) : t -> t -> bool
val (<.) : t -> t -> bool
val (<>.) : t -> t -> bool
val robustly_compare : t -> t -> int
val add : t -> Span.t -> t
val sub : t -> Span.t -> t
val diff : t -> t -> Span.t
val next : t -> t

next t returns the next t (forwards in time)

val prev : t -> t

prev t returns the previous t (backwards in time)

val to_span_since_epoch : t -> Span.t
val of_span_since_epoch : Span.t -> t
include Comparable.S_common with type t := t and module Replace_polymorphic_compare := Replace_polymorphic_compare
include Base.Comparable.S with type t := t
val (>=) : t -> t -> bool
val (<=) : t -> t -> bool
val (=) : t -> t -> bool
val (>) : t -> t -> bool
val (<) : t -> t -> bool
val (<>) : t -> t -> bool
val equal : t -> t -> bool
val compare : t -> t -> int
val min : t -> t -> t
val max : t -> t -> t
val ascending : t -> t -> int
val descending : t -> t -> int
val between : t -> low:t -> high:t -> bool
val clamp_exn : t -> min:t -> max:t -> t
val clamp : t -> min:t -> max:t -> t Base__.Or_error.t
type comparator_witness
val comparator : (t, comparator_witness) Base__Comparator.comparator
val validate_lbound : min:t Maybe_bound.t -> t Validate.check
val validate_ubound : max:t Maybe_bound.t -> t Validate.check
val validate_bound : min:t Maybe_bound.t -> max:t Maybe_bound.t -> t Validate.check
module Date_and_ofday : sig ... end

Equivalent to a Date.t and an Ofday.t with no time zone. A Date_and_ofday.t does not correspond to a single, unambiguous point in time.

val next_multiple : ?can_equal_after:Base.Bool.t -> base:t -> after:t -> interval:Span.t -> Base.Unit.t -> t

next_multiple ~base ~after ~interval returns the smallest time of the form:

time = base + k * interval

where k >= 0 and time > after. It is an error if interval <= 0.

Supplying ~can_equal_after:true allows the result to satisfy time >= after.

val prev_multiple : ?can_equal_before:Base.Bool.t -> base:t -> before:t -> interval:Span.t -> Base.Unit.t -> t

prev_multiple ~base ~before ~interval returns the largest time of the form:

time = base + k * interval

where k >= 0 and time < before. It is an error if interval <= 0.

Supplying ~can_equal_before:true allows the result to satisfy time <= before.

val now : Base.Unit.t -> t
OCaml

Innovation. Community. Security.