public interface EventReceivingStrategy extends EventHandler, Activatable
Handler
s. Implementations have the task of freeing the caller of
EventHandler.handle(rsb.Event)
to dispatch the event in its thread.Activatable.State
Modifier and Type | Method and Description |
---|---|
void |
addFilter(Filter filter)
Adds a filter that is applied for all registered handlers some time after
this method call.
|
void |
addHandler(Handler handler,
boolean wait)
Registers a handler that will be informed in case of received events.
|
void |
removeFilter(Filter filter)
Removes a filter that is remove for all registered handlers some time
after this method call.
|
void |
removeHandler(Handler handler,
boolean wait)
Removes a handler from the event dispatching.
|
handle
activate, deactivate, isActive
void addFilter(Filter filter)
filter
- filter to add, not null
void removeFilter(Filter filter)
filter
- filter to remove, not null
void addHandler(Handler handler, boolean wait) throws InterruptedException
handler
- the handler to add, not null
wait
- if true
, wait with returning from this method
until the handler is fully functional and will receive the
next issued eventInterruptedException
- interrupted while waiting for the handler to be installedvoid removeHandler(Handler handler, boolean wait) throws InterruptedException
handler
- the handler to removewait
- if true
, wait with returning from this method
until the handler cannot receive any more eventsInterruptedException
- interrupted while waiting for the handler to be removedCopyright © 2018 CoR-Lab. All rights reserved.