package chamelon

  1. Overview
  2. Docs
type t
module IdSet : Set.S with type elt := int
val entries : t -> Entry.t list
val commits : t -> Commit.t list
val revision_count : t -> int
val split : t -> (int64 * int64) -> t * t
val linked_blocks : t -> Entry.link list
val hardtail : t -> (int64 * int64) option
val of_commits : hardtail:Entry.t option -> revision_count:int -> Commit.t list -> t
val of_entries : revision_count:int -> Entry.t list -> t
val compact : t -> t
val add_commit : t -> Entry.t list -> t
val ids : t -> IdSet.t
type write_result = [
  1. | `Ok
  2. | `Split
  3. | `Split_emergency
  4. | `Unwriteable
]
val into_cstruct : program_block_size:int -> Cstruct.t -> t -> write_result
val to_cstruct : program_block_size:int -> block_size:int -> t -> Cstruct.t * write_result
val of_cstruct : program_block_size:int -> Cstruct.t -> (t, [ `Msg of string ]) result
OCaml

Innovation. Community. Security.