public interface EventStreamDecorator
Modifier and Type | Method and Description |
---|---|
DomainEventStream |
decorateForAppend(String aggregateType,
EventSourcedAggregateRoot aggregate,
DomainEventStream eventStream)
Called when an event stream is appended to the event store.
|
DomainEventStream |
decorateForRead(String aggregateType,
AggregateIdentifier aggregateIdentifier,
DomainEventStream eventStream)
Called when an event stream is read from the event store.
|
DomainEventStream decorateForRead(String aggregateType, AggregateIdentifier aggregateIdentifier, DomainEventStream eventStream)
eventStream
and pass
that to the chain.aggregateType
- The type of aggregate events are being read foraggregateIdentifier
- The identifier of the aggregate events are loaded foreventStream
- The eventStream containing the events to append to the event store @return The
decorated event streamDomainEventStream decorateForAppend(String aggregateType, EventSourcedAggregateRoot aggregate, DomainEventStream eventStream)
eventStream
and pass
that to the chain.aggregateType
- The type of aggregate events are being appended foraggregate
- The aggregate for which the events are being storedeventStream
- The eventStream containing the events to append to the event store @return The decorated
event streamCopyright © 2012. All Rights Reserved.