public class SimpleEventBus extends AbstractEventBus
AbstractEventBus.SubscriptionEntry<C>exceptionHandlers, idToSubscription, topicToSubscription, undeliveredEventHandlers| Constructor and Description |
|---|
SimpleEventBus(Dispatcher dispatcher)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
void |
dispose()
Disposes the event bus by removing all event handlers, undelivered event handlers, stopping the dispatching
threads, etc.
|
<C> void |
publish(Event<C> event)
Publishes the specified event on the event bus.
|
addExceptionHandler, addUndeliveredEventHandler, createDefaultChannelForHandler, publish, publish, publish, removeExceptionHandler, removeUndeliveredEventHandler, subscribe, subscribe, subscribe, subscribe, unsubscribepublic SimpleEventBus(Dispatcher dispatcher)
dispatcher - Dispatcher strategy to be used by this event bus.public <C> void publish(Event<C> event)
AbstractEventBusThis method is called from the other publish methods.
publish in class AbstractEventBusC - Type of event content.event - Event to be dispatched.AbstractEventBus.publish(Event)public void dispose()
EventBusAfter calling this method, the event bus may no longer be used, depending on the implementation.
dispose in interface EventBusdispose in class AbstractEventBusAbstractEventBus.dispose()Copyright © 2017. All rights reserved.