package base

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

Module Map.PolySource

A polymorphic Map.

Sourcetype ('key, +'value) t = ('key, 'value, Comparator.Poly.comparator_witness) t
Sourcetype ('key, +'value) tree = ('key, 'value, Comparator.Poly.comparator_witness) Using_comparator.Tree.t
Sourceval empty : (_, _) t
Sourceval singleton : 'a -> 'b -> ('a, 'b) t
Sourceval map_keys : ('k1, 'v) t -> f:('k1 -> 'k2) -> [ `Ok of ('k2, 'v) t | `Duplicate_key of 'k2 ]
Sourceval map_keys_exn : ('k1, 'v) t -> f:('k1 -> 'k2) -> ('k2, 'v) t
Sourceval of_alist : ('a * 'b) list -> [ `Ok of ('a, 'b) t | `Duplicate_key of 'a ]
Sourceval of_alist_or_error : ('a * 'b) list -> ('a, 'b) t Or_error.t
Sourceval of_alist_exn : ('a * 'b) list -> ('a, 'b) t
Sourceval of_alist_multi : ('a * 'b) list -> ('a, 'b list) t
Sourceval of_alist_fold : ('a * 'b) list -> init:'c -> f:('c -> 'b -> 'c) -> ('a, 'c) t
Sourceval of_alist_reduce : ('a * 'b) list -> f:('b -> 'b -> 'b) -> ('a, 'b) t
Sourceval of_sorted_array : ('a * 'b) array -> ('a, 'b) t Or_error.t
Sourceval of_sorted_array_unchecked : ('a * 'b) array -> ('a, 'b) t
Sourceval of_increasing_iterator_unchecked : len:int -> f:(int -> 'a * 'b) -> ('a, 'b) t
Sourceval of_increasing_sequence : ('a * 'b) Sequence.t -> ('a, 'b) t Or_error.t
Sourceval of_sequence : ('a * 'b) Sequence.t -> [ `Ok of ('a, 'b) t | `Duplicate_key of 'a ]
Sourceval of_sequence_or_error : ('a * 'b) Sequence.t -> ('a, 'b) t Or_error.t
Sourceval of_sequence_exn : ('a * 'b) Sequence.t -> ('a, 'b) t
Sourceval of_sequence_multi : ('a * 'b) Sequence.t -> ('a, 'b list) t
Sourceval of_sequence_fold : ('a * 'b) Sequence.t -> init:'c -> f:('c -> 'b -> 'c) -> ('a, 'c) t
Sourceval of_sequence_reduce : ('a * 'b) Sequence.t -> f:('b -> 'b -> 'b) -> ('a, 'b) t
Sourceval of_iteri : iteri:(f:(key:'a -> data:'b -> unit) -> unit) -> [ `Ok of ('a, 'b) t | `Duplicate_key of 'a ]
Sourceval of_iteri_exn : iteri:(f:(key:'a -> data:'b -> unit) -> unit) -> ('a, 'b) t
Sourceval of_tree : ('a, 'b) tree -> ('a, 'b) t
Sourceval invariants : (_, _) t -> bool
Sourceval is_empty : (_, _) t -> bool
Sourceval length : (_, _) t -> int
Sourceval add : ('a, 'b) t -> key:'a -> data:'b -> [ `Ok of ('a, 'b) t | `Duplicate ]
Sourceval add_exn : ('a, 'b) t -> key:'a -> data:'b -> ('a, 'b) t
Sourceval set : ('a, 'b) t -> key:'a -> data:'b -> ('a, 'b) t
Sourceval add_multi : ('a, 'b list) t -> key:'a -> data:'b -> ('a, 'b list) t
Sourceval remove_multi : ('a, 'b list) t -> 'a -> ('a, 'b list) t
Sourceval find_multi : ('a, 'b list) t -> 'a -> 'b list
Sourceval change : ('a, 'b) t -> 'a -> f:('b option -> 'b option) -> ('a, 'b) t
Sourceval update : ('a, 'b) t -> 'a -> f:('b option -> 'b) -> ('a, 'b) t
Sourceval find : ('a, 'b) t -> 'a -> 'b option
Sourceval find_exn : ('a, 'b) t -> 'a -> 'b
Sourceval remove : ('a, 'b) t -> 'a -> ('a, 'b) t
Sourceval mem : ('a, 'b) t -> 'a -> bool
Sourceval iter_keys : ('a, _) t -> f:('a -> unit) -> unit
Sourceval iter : (_, 'b) t -> f:('b -> unit) -> unit
Sourceval iteri : ('a, 'b) t -> f:(key:'a -> data:'b -> unit) -> unit
Sourceval iteri_until : ('a, 'b) t -> f:(key:'a -> data:'b -> Continue_or_stop.t) -> Finished_or_unfinished.t
Sourceval iter2 : ('a, 'b) t -> ('a, 'c) t -> f:(key:'a -> data:[ `Left of 'b | `Right of 'c | `Both of 'b * 'c ] -> unit) -> unit
Sourceval map : ('a, 'b) t -> f:('b -> 'c) -> ('a, 'c) t
Sourceval mapi : ('a, 'b) t -> f:(key:'a -> data:'b -> 'c) -> ('a, 'c) t
Sourceval fold : ('a, 'b) t -> init:'c -> f:(key:'a -> data:'b -> 'c -> 'c) -> 'c
Sourceval fold_until : ('k, 'v) t -> init:'a -> f:(key:'k -> data:'v -> 'a -> ('a, 'final) Container.Continue_or_stop.t) -> finish:('a -> 'final) -> 'final
Sourceval fold_right : ('a, 'b) t -> init:'c -> f:(key:'a -> data:'b -> 'c -> 'c) -> 'c
Sourceval fold2 : ('a, 'b) t -> ('a, 'c) t -> init:'d -> f: (key:'a -> data:[ `Left of 'b | `Right of 'c | `Both of 'b * 'c ] -> 'd -> 'd) -> 'd
Sourceval filter_keys : ('a, 'b) t -> f:('a -> bool) -> ('a, 'b) t
Sourceval filter : ('a, 'b) t -> f:('b -> bool) -> ('a, 'b) t
Sourceval filteri : ('a, 'b) t -> f:(key:'a -> data:'b -> bool) -> ('a, 'b) t
Sourceval filter_map : ('a, 'b) t -> f:('b -> 'c option) -> ('a, 'c) t
Sourceval filter_mapi : ('a, 'b) t -> f:(key:'a -> data:'b -> 'c option) -> ('a, 'c) t
Sourceval partition_mapi : ('a, 'b) t -> f:(key:'a -> data:'b -> ('c, 'd) Either.t) -> ('a, 'c) t * ('a, 'd) t
Sourceval partition_map : ('a, 'b) t -> f:('b -> ('c, 'd) Either.t) -> ('a, 'c) t * ('a, 'd) t
Sourceval partitioni_tf : ('a, 'b) t -> f:(key:'a -> data:'b -> bool) -> ('a, 'b) t * ('a, 'b) t
Sourceval partition_tf : ('a, 'b) t -> f:('b -> bool) -> ('a, 'b) t * ('a, 'b) t
Sourceval combine_errors : ('a, 'b Or_error.t) t -> ('a, 'b) t Or_error.t
Sourceval compare_direct : ('b -> 'b -> int) -> ('a, 'b) t -> ('a, 'b) t -> int
Sourceval equal : ('b -> 'b -> bool) -> ('a, 'b) t -> ('a, 'b) t -> bool
Sourceval keys : ('a, _) t -> 'a list
Sourceval data : (_, 'b) t -> 'b list
Sourceval to_alist : ?key_order:[ `Increasing | `Decreasing ] -> ('a, 'b) t -> ('a * 'b) list
Sourceval merge : ('a, 'b) t -> ('a, 'c) t -> f:(key:'a -> [ `Left of 'b | `Right of 'c | `Both of 'b * 'c ] -> 'd option) -> ('a, 'd) t
Sourceval merge_skewed : ('k, 'v) t -> ('k, 'v) t -> combine:(key:'k -> 'v -> 'v -> 'v) -> ('k, 'v) t
Sourceval symmetric_diff : ('a, 'b) t -> ('a, 'b) t -> data_equal:('b -> 'b -> bool) -> ('a * [ `Left of 'b | `Right of 'b | `Unequal of 'b * 'b ]) Sequence.t
Sourceval fold_symmetric_diff : ('a, 'b) t -> ('a, 'b) t -> data_equal:('b -> 'b -> bool) -> init:'c -> f:('c -> ('a * [ `Left of 'b | `Right of 'b | `Unequal of 'b * 'b ]) -> 'c) -> 'c
Sourceval min_elt : ('a, 'b) t -> ('a * 'b) option
Sourceval min_elt_exn : ('a, 'b) t -> 'a * 'b
Sourceval max_elt : ('a, 'b) t -> ('a * 'b) option
Sourceval max_elt_exn : ('a, 'b) t -> 'a * 'b
Sourceval for_all : (_, 'b) t -> f:('b -> bool) -> bool
Sourceval for_alli : ('a, 'b) t -> f:(key:'a -> data:'b -> bool) -> bool
Sourceval exists : (_, 'b) t -> f:('b -> bool) -> bool
Sourceval existsi : ('a, 'b) t -> f:(key:'a -> data:'b -> bool) -> bool
Sourceval count : (_, 'b) t -> f:('b -> bool) -> int
Sourceval counti : ('a, 'b) t -> f:(key:'a -> data:'b -> bool) -> int
Sourceval split : ('a, 'b) t -> 'a -> ('a, 'b) t * ('a * 'b) option * ('a, 'b) t
Sourceval append : lower_part:('a, 'b) t -> upper_part:('a, 'b) t -> [ `Ok of ('a, 'b) t | `Overlapping_key_ranges ]
Sourceval subrange : ('a, 'b) t -> lower_bound:'a Maybe_bound.t -> upper_bound:'a Maybe_bound.t -> ('a, 'b) t
Sourceval fold_range_inclusive : ('a, 'b) t -> min:'a -> max:'a -> init:'c -> f:(key:'a -> data:'b -> 'c -> 'c) -> 'c
Sourceval range_to_alist : ('a, 'b) t -> min:'a -> max:'a -> ('a * 'b) list
Sourceval closest_key : ('a, 'b) t -> [ `Greater_or_equal_to | `Greater_than | `Less_or_equal_to | `Less_than ] -> 'a -> ('a * 'b) option
Sourceval nth : ('a, 'b) t -> int -> ('a * 'b) option
Sourceval nth_exn : ('a, 'b) t -> int -> 'a * 'b
Sourceval rank : ('a, _) t -> 'a -> int option
Sourceval to_tree : ('a, 'b) t -> ('a, 'b) tree
Sourceval to_sequence : ?order:[ `Increasing_key | `Decreasing_key ] -> ?keys_greater_or_equal_to:'a -> ?keys_less_or_equal_to:'a -> ('a, 'b) t -> ('a * 'b) Sequence.t
Sourceval binary_search_segmented : ('k, 'v) t -> segment_of:(key:'k -> data:'v -> [ `Left | `Right ]) -> Binary_searchable.Which_target_by_segment.t -> ('k * 'v) option
Sourceval binary_search_subrange : ('k, 'v) t -> compare:(key:'k -> data:'v -> 'bound -> int) -> lower_bound:'bound Maybe_bound.t -> upper_bound:'bound Maybe_bound.t -> ('k, 'v) t
OCaml

Innovation. Community. Security.