[−][src]Crate cqrs_core
cqrs-core
cqrs-core
defines the core types for the CQRS aggregate system
Modules
reactor |
Structs
AlwaysSnapshot | A snapshot strategy that will always recommend taking a snapshot. |
BorrowedRawEvent | An owned, raw view of event data. |
EventNumber | Represents an event sequence number, starting at 1 |
NeverSnapshot | A snapshot strategy that will never recommend taking a snapshot. |
RawEvent | An owned, raw view of event data. |
VersionedAggregate | A structured tuple combining an aggregate and its current version. |
VersionedEvent | A structured tuple combining an event number and an event. |
VersionedEventWithMetadata | A structured tuple combining an event number and an event. |
Enums
Before | The starting point when reading a stream of values from an [EventSource]. |
Precondition | A precondition that must be upheld for a command to be executed or for events to be persisted. |
Since | The starting point when reading a stream of values from an [EventSource]. |
SnapshotRecommendation | A recommendation on whether or not a snapshot should be persisted. |
Version | An aggregate version. |
Traits
Aggregate | A projected state built from a series of events. |
AggregateCommand | A command that can be executed against an aggregate. |
AggregateEvent | An event that can be applied to an aggregate. |
AggregateId | An identifier for an aggregate. |
CqrsError | Represents a common trait that all errors handled by CQRS should implement. |
DeserializableEvent | An event that can be deserialized from a buffer. |
Event | A thing that happened. |
EventSink | A sink for writing/persisting events with associated metadata. |
EventSource | A source for reading/loading events. |
Events | An iterable and sliceable list of events. |
SerializableEvent | An event that can be serialized to a buffer. |
SnapshotSink | A sink for writing/persisting snapshots of aggregates. |
SnapshotSource | A source for reading/loading snapshots of aggregates. |
SnapshotStrategy | A strategy determining when to recommend a snapshot be taken. |
Type Definitions
CommandError | The error produced when this command cannot be executed against an aggregate. |
ProducedEvent | The event type produced by this command. |
ProducedEvents | The event sequence produced by this command. |