package crdt-ml

  1. Overview
  2. Docs

Module type Immutable_types.RSetSource

Add and remove set type. Supports merging, adding and lookup operations.

include GSet
include Mergeable
Sourcetype t

Type of mergeable elements.

Sourceval make : unit -> t

Create a new mergeable element.

Sourceval merge : t -> t -> t

merge a b will merge the state of a and the one from b to create a new mergeable element.

Sourcetype elt

Type of the contents of GSet

Sourceval add : elt -> t -> t

add el t adds el to t.

Sourceval value : t -> elt list

value t gets the raw state of t.

Sourceval lookup : elt -> t -> bool

lookup el t returns true if el is in t.

Sourceval remove : elt -> t -> t

remove el t removes el from t only if el is in t. Returns t otherwise.

OCaml

Innovation. Community. Security.