Package org.n52.janmayen.event
Class EventBus
java.lang.Object
org.n52.janmayen.event.EventBus
- All Implemented Interfaces:
Constructable
The
EventListener are registered to the EventBus which delegates the fired Event to the
EventListener.- Since:
- 1.0.0
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidinit()Constructs this object.voidregister(EventListener listener) Register a newEventListenerto theEventBus.voidvoidunregister(EventListener listener) Unregister a newEventListenerto theEventBus.
-
Constructor Details
-
EventBus
public EventBus() -
EventBus
public EventBus(boolean async)
-
-
Method Details
-
init
public void init()Description copied from interface:ConstructableConstructs this object.- Specified by:
initin interfaceConstructable
-
submit
- Parameters:
event- SubmittedEvent
-
register
Register a newEventListenerto theEventBus.- Parameters:
listener-EventListenerto register
-
unregister
Unregister a newEventListenerto theEventBus.- Parameters:
listener-EventListenerto unregister
-