public interface EventMessageHandler extends MessageHandler<EventMessage<?>>
EventBus,
DomainEventMessage,
EventHandler| Modifier and Type | Method and Description |
|---|---|
Object |
handle(EventMessage<?> event)
Process the given event.
|
default void |
prepareReset()
Performs any activities that are required to reset the state managed by handlers assigned to this handler.
|
default <R> void |
prepareReset(R resetContext)
Performs any activities that are required to reset the state managed by handlers assigned to this handler.
|
default boolean |
supportsReset()
Indicates whether the handlers managed by this invoker support a reset.
|
canHandle, canHandleType, getTargetTypeObject handle(EventMessage<?> event) throws Exception
handle in interface MessageHandler<EventMessage<?>>event - the event to handleException - when an exception is raised during event handlingdefault void prepareReset()
default <R> void prepareReset(R resetContext)
R - the type of the provided resetContextresetContext - a R used to support the reset operationdefault boolean supportsReset()
true if a reset is supported, otherwise falseCopyright © 2010–2023. All rights reserved.