Definition
Package: MessageHandler.EventSourcing
Assembly: MessageHandler.EventSourcing
Namespace: MessageHandler.EventSourcing.DomainModel
Base class for event sourced entities that implements MessageHandler.EventSourcing.DomainModel.IEventSourced.
Properties
| Property | Description |
|---|---|
| Id | Gets the id of the eventsourced aggregate |
| Version | Gets the entity's version. As the entity is being updated and events being generated, the version is incremented. |
| PendingEvents | Gets the collection of new events since the entity was loaded, as a consequence of command handling. |
| History | Gets the collection of past events. |
Methods
| Method | Description |
|---|---|
| RestoreFrom(IEnumerable |
Restore the inner state from a set of past events. |
| Commit() | Commits the pending events to the event history |
| Append(IEnumerable |
Append a set even events to the pending events, but only if there are no conflicts |
| Rebase(IEnumerable |
Append a set even events to the pending events, while resolving conflicts by reordering the events. |
| Merge(IEnumerable |
Append a set even events to the pending events, while resolving conflicts by joining the conflicting streams through a merge event. |