package tcpip

  1. Overview
  2. Docs
include Lru.F.S with type k = K.t and type v = V.t
type t
type k = K.t
type v = V.t
val empty : int -> t
val is_empty : t -> bool
val items : t -> int
val size : t -> int
val capacity : t -> int
val trim : t -> t
val resize : int -> t -> t
val mem : k -> t -> bool
val find : ?promote:bool -> k -> t -> (v * t) option
val add : ?trim:bool -> k -> v -> t -> t
val remove : k -> t -> t
val unadd : k -> t -> (v * t) option
val lru : t -> (k * v) option
val drop_lru : t -> t
val pop_lru : t -> ((k * v) * t) option
val fold : (k -> v -> 'a -> 'a) -> 'a -> t -> 'a
val iter : (k -> v -> unit) -> t -> unit
val to_list : t -> (k * v) list
val of_list : (k * v) list -> t
val pp : ?pp_size:(Stdlib.Format.formatter -> (int * int) -> unit) -> ?sep:(Stdlib.Format.formatter -> unit -> unit) -> (Stdlib.Format.formatter -> (k * v) -> unit) -> Stdlib.Format.formatter -> t -> unit
val pp_dump : (Stdlib.Format.formatter -> (k * v) -> unit) -> Stdlib.Format.formatter -> t -> unit
OCaml

Innovation. Community. Security.