sig
type 'a sequence = ('a -> unit) -> unit
type 'a printer = Format.formatter -> 'a -> unit
type 'a equal = 'a -> 'a -> bool
module type HashedType =
sig
type t
val equal :
CCPersistentHashtbl.HashedType.t ->
CCPersistentHashtbl.HashedType.t -> bool
val hash : CCPersistentHashtbl.HashedType.t -> int
end
module type S =
sig
type key
type 'a t
val empty : unit -> 'a CCPersistentHashtbl.S.t
val create : int -> 'a CCPersistentHashtbl.S.t
val is_empty : 'a CCPersistentHashtbl.S.t -> bool
val find :
'a CCPersistentHashtbl.S.t -> CCPersistentHashtbl.S.key -> 'a
val get_exn :
CCPersistentHashtbl.S.key -> 'a CCPersistentHashtbl.S.t -> 'a
val get :
CCPersistentHashtbl.S.key -> 'a CCPersistentHashtbl.S.t -> 'a option
val mem :
'a CCPersistentHashtbl.S.t -> CCPersistentHashtbl.S.key -> bool
val length : 'a CCPersistentHashtbl.S.t -> int
val add :
'a CCPersistentHashtbl.S.t ->
CCPersistentHashtbl.S.key -> 'a -> 'a CCPersistentHashtbl.S.t
val replace :
'a CCPersistentHashtbl.S.t ->
CCPersistentHashtbl.S.key -> 'a -> 'a CCPersistentHashtbl.S.t
val update :
'a CCPersistentHashtbl.S.t ->
CCPersistentHashtbl.S.key ->
('a option -> 'a option) -> 'a CCPersistentHashtbl.S.t
val remove :
'a CCPersistentHashtbl.S.t ->
CCPersistentHashtbl.S.key -> 'a CCPersistentHashtbl.S.t
val copy : 'a CCPersistentHashtbl.S.t -> 'a CCPersistentHashtbl.S.t
val merge :
f:(CCPersistentHashtbl.S.key ->
[ `Both of 'a * 'b | `Left of 'a | `Right of 'b ] -> 'c option) ->
'a CCPersistentHashtbl.S.t ->
'b CCPersistentHashtbl.S.t -> 'c CCPersistentHashtbl.S.t
val iter :
'a CCPersistentHashtbl.S.t ->
(CCPersistentHashtbl.S.key -> 'a -> unit) -> unit
val fold :
('b -> CCPersistentHashtbl.S.key -> 'a -> 'b) ->
'b -> 'a CCPersistentHashtbl.S.t -> 'b
val map :
(CCPersistentHashtbl.S.key -> 'a -> 'b) ->
'a CCPersistentHashtbl.S.t -> 'b CCPersistentHashtbl.S.t
val filter :
(CCPersistentHashtbl.S.key -> 'a -> bool) ->
'a CCPersistentHashtbl.S.t -> 'a CCPersistentHashtbl.S.t
val filter_map :
(CCPersistentHashtbl.S.key -> 'a -> 'b option) ->
'a CCPersistentHashtbl.S.t -> 'b CCPersistentHashtbl.S.t
val for_all :
(CCPersistentHashtbl.S.key -> 'a -> bool) ->
'a CCPersistentHashtbl.S.t -> bool
val exists :
(CCPersistentHashtbl.S.key -> 'a -> bool) ->
'a CCPersistentHashtbl.S.t -> bool
val of_seq :
(CCPersistentHashtbl.S.key * 'a) CCPersistentHashtbl.sequence ->
'a CCPersistentHashtbl.S.t
val of_list :
(CCPersistentHashtbl.S.key * 'a) list -> 'a CCPersistentHashtbl.S.t
val add_seq :
'a CCPersistentHashtbl.S.t ->
(CCPersistentHashtbl.S.key * 'a) CCPersistentHashtbl.sequence ->
'a CCPersistentHashtbl.S.t
val add_list :
'a CCPersistentHashtbl.S.t ->
(CCPersistentHashtbl.S.key * 'a) list -> 'a CCPersistentHashtbl.S.t
val to_seq :
'a CCPersistentHashtbl.S.t ->
(CCPersistentHashtbl.S.key * 'a) CCPersistentHashtbl.sequence
val to_list :
'a CCPersistentHashtbl.S.t -> (CCPersistentHashtbl.S.key * 'a) list
val equal :
'a CCPersistentHashtbl.equal ->
'a CCPersistentHashtbl.S.t CCPersistentHashtbl.equal
val pp :
?sep:string ->
?arrow:string ->
CCPersistentHashtbl.S.key CCPersistentHashtbl.printer ->
'a CCPersistentHashtbl.printer ->
'a CCPersistentHashtbl.S.t CCPersistentHashtbl.printer
val stats : 'a CCPersistentHashtbl.S.t -> Hashtbl.statistics
end
module Make :
functor (H : HashedType) ->
sig
type key = H.t
type 'a t
val empty : unit -> 'a t
val create : int -> 'a t
val is_empty : 'a t -> bool
val find : 'a t -> key -> 'a
val get_exn : key -> 'a t -> 'a
val get : key -> 'a t -> 'a option
val mem : 'a t -> key -> bool
val length : 'a t -> int
val add : 'a t -> key -> 'a -> 'a t
val replace : 'a t -> key -> 'a -> 'a t
val update : 'a t -> key -> ('a option -> 'a option) -> 'a t
val remove : 'a t -> key -> 'a t
val copy : 'a t -> 'a t
val merge :
f:(key ->
[ `Both of 'a * 'b | `Left of 'a | `Right of 'b ] -> 'c option) ->
'a t -> 'b t -> 'c t
val iter : 'a t -> (key -> 'a -> unit) -> unit
val fold : ('b -> key -> 'a -> 'b) -> 'b -> 'a t -> 'b
val map : (key -> 'a -> 'b) -> 'a t -> 'b t
val filter : (key -> 'a -> bool) -> 'a t -> 'a t
val filter_map : (key -> 'a -> 'b option) -> 'a t -> 'b t
val for_all : (key -> 'a -> bool) -> 'a t -> bool
val exists : (key -> 'a -> bool) -> 'a t -> bool
val of_seq : (key * 'a) sequence -> 'a t
val of_list : (key * 'a) list -> 'a t
val add_seq : 'a t -> (key * 'a) sequence -> 'a t
val add_list : 'a t -> (key * 'a) list -> 'a t
val to_seq : 'a t -> (key * 'a) sequence
val to_list : 'a t -> (key * 'a) list
val equal : 'a equal -> 'a t equal
val pp :
?sep:string ->
?arrow:string -> key printer -> 'a printer -> 'a t printer
val stats : 'a t -> Hashtbl.statistics
end
end