Uses of Interface
dk.cloudcreate.essentials.reactive.EventHandler
-
Packages that use EventHandler Package Description dk.cloudcreate.essentials.reactive -
-
Uses of EventHandler in dk.cloudcreate.essentials.reactive
Classes in dk.cloudcreate.essentials.reactive that implement EventHandler Modifier and Type Class Description classAnnotatedEventHandler<EVENT_TYPE>Extending this class will allow you to colocate multiple related Event handling methods inside the same class and use it together with theLocalEventBus
Each method must accept a single Event argument, return void and be annotated with theEventHandlerannotation.
The method argument type is matched against the concrete event type usingClass.isAssignableFrom(Class).
The method accessibility can be any combination of private, protected, public, etc.
Example:Methods in dk.cloudcreate.essentials.reactive with parameters of type EventHandler Modifier and Type Method Description LocalEventBus<EVENT_TYPE>LocalEventBus. addAsyncSubscriber(EventHandler<EVENT_TYPE> subscriber)Add an asynchronous subscriber/consumerLocalEventBus<EVENT_TYPE>LocalEventBus. addSyncSubscriber(EventHandler<EVENT_TYPE> subscriber)Add a synchronous subscriber/consumervoidOnErrorHandler. handle(EventHandler<EVENT_TYPE> failingSubscriber, EVENT_TYPE event, Exception exception)Will be called if a given consumer/subscriber fails to handle a messagebooleanLocalEventBus. hasAsyncSubscriber(EventHandler<EVENT_TYPE> subscriber)booleanLocalEventBus. hasSyncSubscriber(EventHandler<EVENT_TYPE> subscriber)LocalEventBus<EVENT_TYPE>LocalEventBus. removeAsyncSubscriber(EventHandler<EVENT_TYPE> subscriber)Remove an asynchronous subscriber/consumerLocalEventBus<EVENT_TYPE>LocalEventBus. removeSyncSubscriber(EventHandler<EVENT_TYPE> subscriber)Remove a synchronous subscriber/consumer
-