package server-reason-react
Install
dune-project
Dependency
Authors
Maintainers
Sources
sha256=557e215377660a5c48c0494704d3d149ff249d4a5669f1749b393176b963ea05
sha512=cc3dd53dd21d2564ad031ca74552587f4a8200833ec80392fd190a55d7a7f83bec0fc57d2ec0e262c0c3ef2e78a89914872ea1588921c3cb8836e8e5f67b4cef
doc/server-reason-react.belt/Belt/MutableMap/index.html
Module Belt.MutableMap
The top level provides generic mutable map operations.
It also has two specialized inner modules Belt.MutableMap.Int and Belt.MutableMap.String
A mutable sorted map module which allows customize compare behavior.
Same as Belt.Map, but mutable.
val clear : (_, _, _) t -> unitval isEmpty : (_, _, _) t -> boolval has : ('k, _, _) t -> 'k -> boolcmp m1 m2 cmp First compare by size, if size is the same, compare by key, value pair
eq m1 m2 eqf tests whether the maps m1 and m2 are equal, that is, contain equal keys and associate them with equal data. eqf is the equality predicate used to compare the data associated with the keys.
val forEachU : ('k, 'a, 'id) t -> ('k -> 'a -> unit) -> unitval forEach : ('k, 'a, 'id) t -> ('k -> 'a -> unit) -> unitforEach m f applies f to all bindings in map m. f receives the 'k as first argument, and the associated value as second argument. The bindings are passed to f in increasing order with respect to the ordering over the type of the keys.
val reduceU : ('k, 'a, 'id) t -> 'b -> ('b -> 'k -> 'a -> 'b) -> 'bval reduce : ('k, 'a, 'id) t -> 'b -> ('b -> 'k -> 'a -> 'b) -> 'breduce m a f computes (f kN dN ... (f k1 d1 a)...), where k1 ... kN are the keys of all bindings in m (in increasing order), and d1 ... dN are the associated data.
val everyU : ('k, 'a, 'id) t -> ('k -> 'a -> bool) -> boolval every : ('k, 'a, 'id) t -> ('k -> 'a -> bool) -> boolevery m p checks if all the bindings of the map satisfy the predicate p.
val someU : ('k, 'a, 'id) t -> ('k -> 'a -> bool) -> boolval some : ('k, 'a, 'id) t -> ('k -> 'a -> bool) -> boolsome m p checks if at least one binding of the map satisfy the predicate p.
val size : ('k, 'a, 'id) t -> intval toList : ('k, 'a, 'id) t -> ('k * 'a) listIn increasing order
val toArray : ('k, 'a, 'id) t -> ('k * 'a) arrayIn increasing order
val keysToArray : ('k, _, _) t -> 'k arrayval valuesToArray : (_, 'a, _) t -> 'a arrayval minKey : ('k, _, _) t -> 'k optionval minKeyUndefined : ('k, _, _) t -> 'k Js.undefinedval maxKey : ('k, _, _) t -> 'k optionval maxKeyUndefined : ('k, _, _) t -> 'k Js.undefinedval minimum : ('k, 'a, _) t -> ('k * 'a) optionval minUndefined : ('k, 'a, _) t -> ('k * 'a) Js.undefinedval maximum : ('k, 'a, _) t -> ('k * 'a) optionval maxUndefined : ('k, 'a, _) t -> ('k * 'a) Js.undefinedval get : ('k, 'a, 'id) t -> 'k -> 'a optionval getUndefined : ('k, 'a, 'id) t -> 'k -> 'a Js.undefinedval getWithDefault : ('k, 'a, 'id) t -> 'k -> 'a -> 'aval getExn : ('k, 'a, 'id) t -> 'k -> 'aval checkInvariantInternal : (_, _, _) t -> unitraise when invariant is not held
val remove : ('k, 'a, 'id) t -> 'k -> unitremove m x do the in-place modification,
val removeMany : ('k, 'a, 'id) t -> 'k array -> unitval set : ('k, 'a, 'id) t -> 'k -> 'a -> unitset m x y do the in-place modification
val updateU : ('k, 'a, 'id) t -> 'k -> ('a option -> 'a option) -> unitval update : ('k, 'a, 'id) t -> 'k -> ('a option -> 'a option) -> unitval mergeMany : ('k, 'a, 'id) t -> ('k * 'a) array -> unitmap m f returns a map with same domain as m, where the associated value a of all bindings of m has been replaced by the result of the application of f to a. The bindings are passed to f in increasing order with respect to the ordering over the type of the keys.