package dokeysto

  1. Overview
  2. Docs

Module Db.ROSource

Sourcetype t
Sourceval open_existing : filename -> t

open_existing fn open in read-only mode the persistent hashtbl whose data are stored in file fn and whose index is stored in fn ^ ".idx".

Sourceval dummy : unit -> t

dummy () create a value of type t. Do not do anything with this value.

Sourceval close : t -> unit

close db close the previously opened db.

Sourceval mem : t -> string -> bool

mem db k check if k is bound in db.

Sourceval find : t -> string -> string

find db k get the current binding of k in db or raise Not_found.

Sourceval raw_read : t -> position -> string

raw_read db pos read from the data file of db the string at position pos. WARNING: regular users should not need to call this function.

Sourceval iter : (string -> string -> unit) -> t -> unit

iter f db apply f to all key-value pairs in db. Cf. Hashtbl.iter for details.

Sourceval fold : (string -> string -> 'acc -> 'acc) -> t -> 'acc -> 'acc

fold f db init fold f over all key-value pairs in db. Cf. Hashtbl.fold for details.

OCaml

Innovation. Community. Security.