I
- The type of the identifier of this aggregate@MappedSuperclass public abstract class AbstractAnnotatedAggregateRoot<I> extends AbstractEventSourcedAggregateRoot<I>
EventHandler
annotation.
Implementations can call the AbstractEventSourcedAggregateRoot.apply(Object)
method to have an event applied.EventHandler
,
Serialized FormConstructor and Description |
---|
AbstractAnnotatedAggregateRoot() |
Modifier and Type | Method and Description |
---|---|
protected Collection<EventSourcedEntity> |
getChildEntities()
Returns a collection of event sourced entities directly referenced by this entity.
|
I |
getIdentifier()
Returns the identifier of this aggregate.
|
protected void |
handle(DomainEventMessage event)
Calls the appropriate
EventHandler annotated handler with the
provided event. |
apply, apply, getVersion, initializeState
addEventRegistrationCallback, commitEvents, getLastCommittedEventSequenceNumber, getUncommittedEventCount, getUncommittedEvents, initializeEventStream, isDeleted, markDeleted, registerEvent, registerEvent
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
addEventRegistrationCallback, commitEvents, getUncommittedEventCount, getUncommittedEvents, isDeleted
protected void handle(DomainEventMessage event)
EventHandler
annotated handler with the
provided event.handle
in class AbstractEventSourcedAggregateRoot<I>
event
- The event to handleEventHandler
public I getIdentifier()
AggregateRoot
protected Collection<EventSourcedEntity> getChildEntities()
AbstractEventSourcedAggregateRoot
getChildEntities
in class AbstractEventSourcedAggregateRoot<I>
Copyright © 2010-2013. All Rights Reserved.