kofre.datatypes
Members list
Packages
Type members
Classlikes
Attributes
- Companion
- object
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
Attributes
- Companion
- object
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
A GCounter is a Delta CRDT modeling an increment-only counter.
A GCounter is a Delta CRDT modeling an increment-only counter.
Attributes
- Companion
- class
- Supertypes
-
trait Producttrait Mirrorclass Objecttrait Matchableclass Any
- Self type
-
GrowOnlyCounter.type
A GrowOnlyList is a Delta CRDT modeling a grow-only list where list elements can neither be removed nor modified.
A GrowOnlyList is a Delta CRDT modeling a grow-only list where list elements can neither be removed nor modified.
Concurrent inserts at the same index i are resolved by the timestamps of the insert operations: the later insert will be at index i while the earlier insert will be pushed to index i+1.
Note: GrowOnlyList is implemented as a linked list, thus the time needed to execute operations at the end of the list will scale linearly with the length of the list. Similarly, toList always has to iterate the whole list, so for applications that don't always need the whole list you should consider using toLazyList instead.
Attributes
- Companion
- object
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
Attributes
- Companion
- class
- Supertypes
-
trait Producttrait Mirrorclass Objecttrait Matchableclass Any
- Self type
-
GrowOnlyList.type
Attributes
- Supertypes
-
class Objecttrait Matchableclass Any
- Self type
-
GrowOnlyMap.type
A GrowOnlySet is a Delta CRDT modeling a simple grow-only set.
A GrowOnlySet is a Delta CRDT modeling a simple grow-only set.
Attributes
- Supertypes
-
class Objecttrait Matchableclass Any
- Self type
-
GrowOnlySet.type
A LastWriterWins (register) is a common fallback for datatypes that don’t have good merge semantics.
A LastWriterWins (register) is a common fallback for datatypes that don’t have good merge semantics.
Concurrent writes are resolved by wallclock time first (favouring replicas with clock drift into the future), and by replica ID, in case both writes happened in the same millisecond.
Attributes
- Companion
- object
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
Attributes
- Companion
- class
- Supertypes
-
trait Producttrait Mirrorclass Objecttrait Matchableclass Any
- Self type
-
LastWriterWins.type
Attributes
- Companion
- object
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
A PNCounter (Positive-Negative Counter) is a Delta CRDT modeling a counter.
A PNCounter (Positive-Negative Counter) is a Delta CRDT modeling a counter.
It is composed of two grow-only counters (see GrowOnlyCounter) to enable both increments and decrements of the counter value.
Attributes
- Companion
- class
- Supertypes
-
trait Producttrait Mirrorclass Objecttrait Matchableclass Any
- Self type
-
PosNegCounter.type
A TwoPhaseSet (Two-Phase Set) is a Delta CRDT modeling a set.
A TwoPhaseSet (Two-Phase Set) is a Delta CRDT modeling a set.
The set is modeled as two grow-only sets, a set of added elements and a set of removed elements. Because of this, elements that were removed from the set once can never be re-added.
Attributes
- Companion
- object
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
Attributes
- Companion
- class
- Supertypes
-
trait Producttrait Mirrorclass Objecttrait Matchableclass Any
- Self type
-
TwoPhaseSet.type
Types
A GMap (Grow-only Map) is a Delta CRDT that models a map from an arbitrary key type to nested Delta CRDTs. In contrast to kofre.datatypes.contextual.ObserveRemoveMap, key/value pairs cannot be removed from this map. However, due to the smaller internal representation, mutate operations on large maps are a lot faster than on ObserveRemoveMap.
A GMap (Grow-only Map) is a Delta CRDT that models a map from an arbitrary key type to nested Delta CRDTs. In contrast to kofre.datatypes.contextual.ObserveRemoveMap, key/value pairs cannot be removed from this map. However, due to the smaller internal representation, mutate operations on large maps are a lot faster than on ObserveRemoveMap.
The nested CRDTs can be queried/mutated by calling the queryKey/mutateKey methods with a DeltaQuery/DeltaMutator generated by a CRDT Interface method of the nested CRDT. For example, to enable a nested EWFlag, one would pass EWFlagInterface.enable()
as the DeltaMutator to mutateKey.