Event sourcing aggregate is using/delegating a EventSourcingAggregate.decider of type IDecider<C, S, E> to handle commands and produce events.
In order to handle the command, aggregate needs to fetch the current state (represented as a list of events) via IEventRepository.fetchEvents function, and then delegate the command to the EventSourcingAggregate.decider which can produce new event(s) as a result.
Produced events are then stored via IEventRepository.save function.
Event sourcing aggregate is using/delegating a
EventSourcingAggregate.decider
of typeIDecider
<C
,S
,E
> to handle commands and produce events. In order to handle the command, aggregate needs to fetch the current state (represented as a list of events) viaIEventRepository.fetchEvents
function, and then delegate the command to theEventSourcingAggregate.decider
which can produce new event(s) as a result.Produced events are then stored via
IEventRepository.save
function.Type Param: E
Version
Author
Иван Дугалић / Ivan Dugalic /
Idugalic