public interface ApplicationEventPublisher
Interface for classes that publish events received by ApplicationEventListener
instances.
Note that this interface is designed for application level, non-blocking synchronous events for decoupling code and is not a replacement for a messaging system
Modifier and Type | Method and Description |
---|---|
void |
publishEvent(Object event)
Publish the given event.
|
default Future<Void> |
publishEventAsync(Object event)
Publish the given event.
|
void publishEvent(@Nonnull Object event)
event
- The event to publishdefault Future<Void> publishEventAsync(@Nonnull Object event)
event
- The event to publish