package tezos-context

  1. Overview
  2. Docs
Tezos: on-disk context abstraction for `octez-node`

Install

Dune Dependency

Authors

Maintainers

Sources

tezos-17.3.tar.gz
sha256=7062cd57addd452852598a2214ade393130efa087b99068d53713bdf912b3680
sha512=08e4091144a03ce3c107fb91a66501bd8b65ca3278917c455a2eaac6df3e108ade63f6ab8340a4bb152d60f404326e464d0ec95d26cafe8e82f870465d24a5fc

doc/tezos-context.helpers/Tezos_context_helpers/Context/Make_proof/argument-1-DB/Branch/index.html

Module DB.Branch

Manipulate branches.

Branch Store

Manipulate relations between branches and commits.

val mem : repo -> branch -> bool Lwt.t

mem r b is true iff b is present in r.

val find : repo -> branch -> commit option Lwt.t

find r b is Some c iff c is bound to b in t. It is None if b is not present in t.

val get : repo -> branch -> commit Lwt.t

get t b is similar to find but raise Invalid_argument if b is not present in t.

val set : repo -> branch -> commit -> unit Lwt.t

set t b c bounds c to b in t.

val remove : repo -> branch -> unit Lwt.t

remove t b removes b from t.

val list : repo -> branch list Lwt.t

list t is the list of branches present in t.

val watch : repo -> branch -> ?init:commit -> (commit Irmin.Diff.t -> unit Lwt.t) -> watch Lwt.t

watch t b f calls f on every change in b.

val watch_all : repo -> ?init:(branch * commit) list -> (branch -> commit Irmin.Diff.t -> unit Lwt.t) -> watch Lwt.t

watch_all t f calls f on every branch-related change in t, including creation/deletion events.

Base functions for branches.

include Irmin.Branch.S with type t = branch

Signature for Branches

type t = branch

The type for branches.

val t : t Irmin.Type.t
val main : t

The name of the main branch.

val is_valid : t -> bool

Check if the branch is valid.

OCaml

Innovation. Community. Security.