public abstract class AdaptrisMessageConsumerImp extends AdaptrisMessageWorkerImp implements AdaptrisMessageConsumer, StateManagedComponent
Implementation of behaviour common to AdaptrisMessageConsumer
s.
log
Constructor and Description |
---|
AdaptrisMessageConsumerImp() |
Modifier and Type | Method and Description |
---|---|
void |
changeState(ComponentState newState)
Updates the state for the component
ComponentState . |
protected abstract java.lang.String |
newThreadName() |
void |
registerAdaptrisMessageListener(AdaptrisMessageListener l)
Sets the
AdaptrisMessageListener to use. |
protected java.lang.String |
renameThread()
Rename the thread to something suitable.
|
void |
requestClose()
Request this component is closed.
|
void |
requestInit()
Request this component is init'd.
|
void |
requestStart()
Request this component is started.
|
void |
requestStop()
Request this component is stopped.
|
AdaptrisMessageListener |
retrieveAdaptrisMessageListener()
Returns the
AdaptrisMessageListener to use. |
ComponentState |
retrieveComponentState()
Returns the last recorde
ComponentState . |
createName, createQualifier, decode, encode, getEncoder, getIsTrackingEndpoint, getMessageFactory, getUniqueId, handleConnectionException, isTrackingEndpoint, registerConnection, registerEncoderMessageFactory, retrieveConnection, setEncoder, setIsTrackingEndpoint, setMessageFactory, setUniqueId, withMessageFactory, withUniqueID
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
consumeLocationKey
decode, encode, getEncoder, getMessageFactory, handleConnectionException, registerConnection, retrieveConnection, setEncoder, setMessageFactory
getUniqueId
close, init, start, stop
prepare
createName, createQualifier, isTrackingEndpoint
public void registerAdaptrisMessageListener(AdaptrisMessageListener l)
Sets the AdaptrisMessageListener
to use.
registerAdaptrisMessageListener
in interface AdaptrisMessageConsumer
l
- the AdaptrisMessageListener
to usepublic AdaptrisMessageListener retrieveAdaptrisMessageListener()
Returns the AdaptrisMessageListener
to use.
AdaptrisMessageListener
to useprotected java.lang.String renameThread()
protected abstract java.lang.String newThreadName()
public void changeState(ComponentState newState)
StateManagedComponent
Updates the state for the component ComponentState
.
changeState
in interface StateManagedComponent
public ComponentState retrieveComponentState()
StateManagedComponent
Returns the last recorde ComponentState
.
retrieveComponentState
in interface StateManagedComponent
ComponentState
public void requestInit() throws CoreException
StateManagedComponent
Request this component is init'd.
requestInit
in interface StateManagedComponent
CoreException
- wrapping any underlying Exceptionspublic void requestStart() throws CoreException
StateManagedComponent
Request this component is started.
requestStart
in interface StateManagedComponent
CoreException
- wrapping any underlying Exceptionspublic void requestStop()
StateManagedComponent
Request this component is stopped.
requestStop
in interface StateManagedComponent
public void requestClose()
StateManagedComponent
Request this component is closed.
requestClose
in interface StateManagedComponent