package crdt-ml

  1. Overview
  2. Docs

Creates an add / remove set of elements satisfying Mutable_types.Comparable

Parameters

Signature

include Mutable_types.GSet with type elt = O.t
include Mutable_types.Mergeable
type t

Type of mergeable elements.

val make : unit -> t

Create a new mergeable element.

val merge : t -> t -> unit

merge a b will merge the state of b with the one from a. Updates a.

type elt = O.t

Type of the contents of GSet

val add : elt -> t -> unit

add el t adds el in-place to t.

val value : t -> elt list

value t gets the raw state of t.

val lookup : elt -> t -> bool

lookup el t returns true if el is in t.

val remove : elt -> t -> unit

remove el t removes el from t only if el is in t. Does nothing otherwise.

OCaml

Innovation. Community. Security.