public abstract class AbstractRSBListenerConnection extends Object implements org.openbase.jul.iface.Launchable<Void>, org.openbase.jul.iface.VoidInitializable, LocalConfigProviderInterface
| Modifier and Type | Field and Description |
|---|---|
protected boolean |
initialized
Initialized state of this class.
|
protected org.openbase.jul.schedule.WatchDog |
listenerWatchDog
WatchDog to control states of the listener.
|
| Constructor and Description |
|---|
AbstractRSBListenerConnection(rsb.AbstractEventHandler handler)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
void |
activate() |
void |
deactivate() |
protected abstract org.openbase.jul.extension.rsb.iface.RSBListener |
getInitializedListener()
Gets the initialized RSB Listener.
|
void |
init() |
protected void |
initListener()
Initializes the RSB Listener
|
boolean |
isActive() |
protected <M extends com.google.protobuf.GeneratedMessage & com.google.protobuf.MessageOrBuilder> |
registerConverterForType(M defaultInstance)
Registers the converter of the given type for the use of informers and
listeners.
|
protected abstract void |
registerConverters()
Registers the converters needed by the listener.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitregisterShutdownHook, registerShutdownHookgetLocalConfigprotected org.openbase.jul.schedule.WatchDog listenerWatchDog
protected boolean initialized
public AbstractRSBListenerConnection(rsb.AbstractEventHandler handler)
handler - is used to handle incoming events.protected abstract org.openbase.jul.extension.rsb.iface.RSBListener getInitializedListener()
throws org.openbase.jul.exception.InitializationException
org.openbase.jul.exception.InitializationException - is thrown, if the initialization of the
Listener fails.protected abstract void registerConverters()
protected <M extends com.google.protobuf.GeneratedMessage & com.google.protobuf.MessageOrBuilder> void registerConverterForType(M defaultInstance)
M - The type that is being registered.defaultInstance - The default instance of the type to be registered.protected void initListener()
throws org.openbase.jul.exception.InitializationException,
InterruptedException
org.openbase.jul.exception.InitializationException - is thrown if
the initialization fails.InterruptedException - is thrown in case of an external
interruption.public void init()
throws org.openbase.jul.exception.InitializationException,
InterruptedException
init in interface org.openbase.jul.iface.DefaultInitializableinit in interface org.openbase.jul.iface.DefaultInitializableImpl<Void>init in interface org.openbase.jul.iface.VoidInitializableorg.openbase.jul.exception.InitializationExceptionInterruptedExceptionpublic void activate()
throws org.openbase.jul.exception.CouldNotPerformException,
InterruptedException
activate in interface org.openbase.jul.iface.Activatableorg.openbase.jul.exception.CouldNotPerformExceptionInterruptedExceptionpublic void deactivate()
throws org.openbase.jul.exception.CouldNotPerformException,
InterruptedException
deactivate in interface org.openbase.jul.iface.Activatableorg.openbase.jul.exception.CouldNotPerformExceptionInterruptedExceptionpublic boolean isActive()
isActive in interface org.openbase.jul.iface.ActivatableCopyright © 2016–2017 openbase.org. All rights reserved.