@Retention(value=RUNTIME) @Target(value=METHOD) public @interface Apply
As we apply the event to the aggregate state, we call such a method Event Applier.
An event applier method:
EventMessageas the only parameter.
To update the state of the aggregate, the
should be used.
If the annotation comes with the attribute
allowImport set to
true, the aggregate can receive incoming events as if they were produced
by the aggregate.
|Modifier and Type||Optional Element and Description|
public abstract boolean allowImport
truethe aggregate supports importing of events with the messages defined as the first parameter of the annotated method.