module Map: sig
.. end
String maps.
String maps
include Map.S
type 'a
t = 'a Astring.String.map
val min_binding : 'a Astring.String.map -> (string * 'a) option
Exception safe Map.S.min_binding
.
val get_min_binding : 'a Astring.String.map -> string * 'a
val max_binding : 'a Astring.String.map -> (string * 'a) option
Exception safe Map.S.max_binding
.
val get_max_binding : 'a Astring.String.map -> string * 'a
val choose : 'a Astring.String.map -> (string * 'a) option
Exception safe Map.S.choose
.
val get_any_binding : 'a Astring.String.map -> string * 'a
val find : string -> 'a Astring.String.map -> 'a option
Exception safe Map.S.find
.
val get : string -> 'a Astring.String.map -> 'a
get k m
is like Map.S.find
but raises Invalid_argument
if
k
is not bound in m
.
val dom : 'a Astring.String.map -> Astring.String.set
dom m
is the domain of m
.
val of_list : (string * 'a) list -> 'a Astring.String.map
of_list bs
is List.fold_left (fun m (k, v) -> add k v m) empty
bs
.
val pp : ?sep:(Format.formatter -> unit -> unit) ->
(Format.formatter -> string * 'a -> unit) ->
Format.formatter -> 'a Astring.String.map -> unit
pp ~sep pp_binding ppf m
formats the bindings of m
on
ppf
. Each binding is formatted with pp_binding
and
bindings are separated by sep
(defaults to
Format.pp_print_cut
). If the map is empty leaves ppf
untouched.
val dump : (Format.formatter -> 'a -> unit) ->
Format.formatter -> 'a Astring.String.map -> unit
dump pp_v ppf m
prints an unspecified representation of m
on
ppf
using pp_v
to print the map codomain elements.
val dump_string_map : Format.formatter -> string Astring.String.map -> unit
dump_string_map ppf m
prints an unspecified representation of the
string map m
on ppf
.