A network connection establishment library
Module Conduit_trie
type 'a t

Radix tree that maps string keys to 'a values

include Sexplib0.Sexpable.S1 with type 'a t := 'a t
val t_of_sexp : ( Sexplib0.Sexp.t -> 'a ) -> Sexplib0.Sexp.t -> 'a t
val sexp_of_t : ( 'a -> Sexplib0.Sexp.t ) -> 'a t -> Sexplib0.Sexp.t
val empty : 'a t

An empty tree

val insert : string -> 'a -> 'a t -> 'a t

insert key value tree returns a new tree with the mapping key to value

val longest_prefix : string -> 'a t -> 'a option

longest_prefix key tree finds the key k which shares the longest prefix with key and returns the associated value.

val fold : ( string -> 'a -> 'b -> 'b ) -> 'b -> 'a t -> 'b

fold f initial t folds f over all bindings in t

val is_prefix : string -> string -> bool

is_prefix a b returns true if a is a prefix of b