The dimensions of an append that take part in its concurrency check.
Written as a list of atoms — :event_source_id, :event_source_type,
:event_stream_type, :event_stream_id — or :none / [] for no
dimensions. The wire representation is the flags value of the Chronicle
ConcurrencyDimensions contract.
Summary
Functions
Normalizes dimensions given as atoms, a list of atoms, or a flags integer into a sorted list.
Returns the flags integer sent on the wire.
Types
@type dimension() ::
:event_source_id | :event_source_type | :event_stream_type | :event_stream_id
@type t() :: [dimension()]
Functions
@spec normalize(:none | dimension() | [dimension()] | non_neg_integer() | nil) :: t()
Normalizes dimensions given as atoms, a list of atoms, or a flags integer into a sorted list.
@spec to_flags(:none | dimension() | [dimension()] | non_neg_integer() | nil) :: non_neg_integer()
Returns the flags integer sent on the wire.