package crdt-ml

  1. Overview
  2. Docs

Module type Mutable_types.GSetSource

Grow-Only set type. Supports merging, adding and lookup operations.

include Mergeable
Sourcetype t

Type of mergeable elements.

Sourceval make : unit -> t

Create a new mergeable element.

Sourceval merge : t -> t -> unit

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

Sourcetype elt

Type of the contents of GSet

Sourceval add : elt -> t -> unit

add el t adds el in-place 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.