package core_extended

  1. Overview
  2. Docs
Legend:
Library
Module
Module type
Parameter
Class
Class type

Parameters

Signature

include S with type in_value = Fold.data with type out_value = Fold.t
type in_value = Fold.data

The type of the values being fold over.

type out_value = Fold.t

The type of the accumulator

type 'key t = private ('key, out_value) Core.Map.Poly.t
type 'a _in_value = in_value
type 'a _out_value = out_value
type ('a, 'b) _t = 'a t
val empty : _ t

A map containing no bindings

val singleton : 'a -> in_value -> 'a t
val is_empty : _ t -> bool
val length : _ t -> int
val add : key:'a -> data:in_value -> 'a t -> 'a t

add m ~key ~data adds the key to the value already bound to key in m. If no value is bound to key than the initial value specified by the functor will be used instead.

val find : 'a t -> 'a -> out_value
val remove : 'a t -> 'a -> 'a t
val set : key:'a -> data:out_value -> 'a t -> 'a t
val mem : 'a t -> 'a -> bool
val iter_keys : 'a t -> f:('a -> unit) -> unit
val iter : 'a t -> f:(out_value -> unit) -> unit
val iteri : 'a t -> f:(key:'a -> data:out_value -> unit) -> unit
val fold : 'a t -> init:'b -> f:(key:'a -> data:out_value -> 'b -> 'b) -> 'b
val filter_keys : 'a t -> f:('a -> bool) -> 'a t
val filter : 'a t -> f:(out_value -> bool) -> 'a t
val filteri : 'a t -> f:(key:'a -> data:out_value -> bool) -> 'a t
val keys : 'a t -> 'a list
val data : _ t -> out_value list
val to_alist : ?key_order:[ `Increasing | `Decreasing ] -> 'a t -> ('a * out_value) list
val of_list : ('a * in_value) list -> 'a t
val for_all : _ t -> f:(out_value -> bool) -> bool
val exists : _ t -> f:(out_value -> bool) -> bool
val to_map : 'a t -> ('a, out_value) Core.Map.Poly.t
val of_map : ('a, out_value) Core.Map.Poly.t -> 'a t
include Core.Sexpable.S1 with type 'key t := 'key t
val t_of_sexp : (Base__.Sexplib.Sexp.t -> 'a) -> Base__.Sexplib.Sexp.t -> 'a t
val sexp_of_t : ('a -> Base__.Sexplib.Sexp.t) -> 'a t -> Base__.Sexplib.Sexp.t
OCaml

Innovation. Community. Security.