package irmin-pack

  1. Overview
  2. Docs
Legend:
Library
Module
Module type
Parameter
Class
Class type
type t
type path := string
exception RO_Not_Allowed
val v : version:[ `V1 | `V2 ] option -> fresh:bool -> readonly:bool -> path -> t
val name : t -> string
val clear : ?keep_generation:unit -> t -> unit
val append : t -> string -> unit
val set : t -> off:int64 -> string -> unit
val read : t -> off:int64 -> bytes -> int
val offset : t -> int64
val force_offset : t -> int64
val generation : t -> int64
val force_generation : t -> int64
val readonly : t -> bool
val version : t -> [ `V1 | `V2 ]
val flush : t -> unit
val close : t -> unit
val exists : string -> bool
val size : t -> int
val truncate : t -> unit

Sets the length of the underlying IO to be 0, without actually purging the associated data. Not supported for stores beyond `V1, which should use clear instead.

val migrate : progress:(int64 -> unit) -> t -> [ `V1 | `V2 ] -> (unit, [> `Msg of string ]) result
  • raises Invalid_arg

    if the migration path is not supported.

val read_buffer : chunk:int -> off:int64 -> t -> string
OCaml

Innovation. Community. Security.