module Multi_map:sig..end
This is a map that allows multiple binding. Each key can have several values
associated to it.
type ('k, 'v) t
include Sexpable.S2
val empty : ('k, 'v) tval singleton : 'k -> 'v -> ('k, 'v) tval is_empty : ('k, 'v) t -> boolval add : key:'k -> data:'v -> ('k, 'v) t -> ('k, 'v) tval find : ('k, 'v) t -> 'k -> 'v listfind m key returns all the elements that where added to key in m in
the reverse order in which they where added. If no element where added an
empty list is returned.val remove : ('k, 'v) t -> 'k -> ('k, 'v) tremove m key Remove all the values associated the key key in mval set : key:'k -> data:'v list -> ('k, 'v) t -> ('k, 'v) tval mem : ('k, 'v) t -> 'k -> boolmem m key returns true if key has at last one value associated to it
in mval keys : ('k, 'v) t -> 'k listm.val iter : f:(key:'k -> data:'v -> unit) -> ('k, 'v) t -> unitval map : f:('a -> 'b) -> ('k, 'a) t -> ('k, 'b) tval mapi : f:(key:'k -> data:'a -> 'b) -> ('k, 'a) t -> ('k, 'b) tval fold : f:(key:'k -> data:'v -> 'a -> 'a) -> ('k, 'v) t -> init:'a -> 'aval filter : f:(key:'k -> data:'v -> bool) -> ('k, 'v) t -> ('k, 'v) tval reduce : f:('v list -> 'r) -> ('k, 'v) t -> ('k, 'r) Core.Std.Map.Poly.t