Package com.slack.api.app_backend.events
Interface EventsDispatcher
-
- All Known Implementing Classes:
EventsDispatcherImpl
public interface EventsDispatcherEvents API requests dispatcher.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidderegister(EventHandler<? extends EventsApiPayload<?>> handler)Removes an EventHandler.voiddispatch(String json)Dispatches requests to appropriate event handlers.voidenqueue(String json)Enqueues a JSON payload to the internal queue.booleanisEmpty()booleanisRunning()voidregister(EventHandler<? extends EventsApiPayload<?>> handler)Registers a new EventHandler.voidstart()Starts the internal thread to handle requests.voidstop()Stops the internal thread to handle requests.
-
-
-
Method Detail
-
isRunning
boolean isRunning()
-
isEmpty
boolean isEmpty()
-
register
void register(EventHandler<? extends EventsApiPayload<?>> handler)
Registers a new EventHandler.
-
deregister
void deregister(EventHandler<? extends EventsApiPayload<?>> handler)
Removes an EventHandler.
-
dispatch
void dispatch(String json)
Dispatches requests to appropriate event handlers.
-
enqueue
void enqueue(String json)
Enqueues a JSON payload to the internal queue.
-
start
void start()
Starts the internal thread to handle requests.
-
stop
void stop()
Stops the internal thread to handle requests.
-
-