package irmin-pack

  1. Overview
  2. Docs
Irmin backend which stores values in a pack file

Install

Dune Dependency

Authors

Maintainers

Sources

irmin-3.6.1.tbz
sha256=11fc2570bdbfd48478c89113fc801084a84a9a2c12d9bf8c64e05ce64ae19bd7
sha512=2171699ca24dec5c9c908a2676b272e034c14eb17f7052a794535e52af0be40be68a689e59c0a640ee244b11703320483f4d0c261542e6242ba23a8f1272b9b0

doc/irmin-pack.unix/Irmin_pack_unix/Index/Make/index.html

Module Index.MakeSource

An abstraction on top of the index library that exposes an API that better fits the irmin-pack use case.

Parameters

module K : Irmin.Hash.S

Signature

Sourcetype t
Sourcetype key = K.t
include Index.S with type value := value and type t := t and type key := key
Sourcetype cache

The type for caches of index instances.

Sourceval empty_cache : unit -> cache

Construct a new empty cache of index instances.

Sourceval clear : t -> unit

clear t clears t so that there are no more bindings in it.

Sourceval replace : ?overcommit:bool -> t -> key -> value -> unit

replace t k v binds k to v in t, replacing any existing binding of k.

If overcommit is true, the operation does not triger a merge, even if the caches are full. By default overcommit is false.

Sourceval sync : t -> unit

sync t syncs a read-only index with the files on disk. Raises RW_not_allowed if called by a read-write index.

Sourceval is_merging : t -> bool

is_merging t returns true if t is running a merge. Raises RO_not_allowed if called by a read-only index.

Sourcemodule Checks : sig ... end

Offline fsck-like utility for checking the integrity of Index stores built using this module.

Sourcemodule Io = Io.Unix
Sourceval v_exn : ?flush_callback:(unit -> unit) -> ?fresh:bool -> ?readonly:bool -> ?throttle:[ `Block_writes | `Overcommit_memory ] -> ?lru_size:int -> log_size:int -> string -> t
type create_error := [
  1. | `Index_failure of string
  2. | `Io_misc of Io.misc_error
]
type write_error := [
  1. | `Index_failure of string
  2. | `Io_misc of Io.misc_error
  3. | `Ro_not_allowed
]
Sourceval v : ?flush_callback:(unit -> unit) -> ?fresh:bool -> ?readonly:bool -> ?throttle:[ `Block_writes | `Overcommit_memory ] -> ?lru_size:int -> log_size:int -> string -> (t, [> create_error ]) result
Sourceval reload : t -> (unit, [> write_error ]) result
Sourceval close : t -> (unit, [> write_error ]) result
Sourceval close_exn : t -> unit
Sourceval flush : t -> with_fsync:bool -> (unit, [> write_error ]) result
Sourceval find : t -> key -> value option
Sourceval add : ?overcommit:bool -> t -> key -> value -> unit
Sourceval merge : t -> unit
Sourceval mem : t -> key -> bool
Sourceval iter : (key -> value -> unit) -> t -> unit
Sourceval filter : t -> ((key * value) -> bool) -> unit
Sourceval try_merge : t -> unit
Sourcemodule Stats = Index.Stats
Sourcemodule Key : Index.Key.S with type t = key
OCaml

Innovation. Community. Security.