public abstract class CacheServiceImpl extends ServiceImp implements ConnectedService
log| Constructor and Description |
|---|
CacheServiceImpl() |
| Modifier and Type | Method and Description |
|---|---|
void |
closeService() |
AdaptrisConnection |
getConnection()
Returns the
AdaptrisConnection to use. |
void |
initService() |
void |
prepare()
Prepare for initialisation.
|
protected Cache |
retrieveCache() |
void |
setConnection(AdaptrisConnection cacheConnection)
Set the connection associated with this cache service.
|
void |
start()
Starts the component.
|
void |
stop()
Stop the component
|
<T extends CacheServiceImpl> |
withConnection(AdaptrisConnection c) |
changeState, close, continueOnFailure, createName, createQualifier, getContinueOnFail, getIsTrackingEndpoint, getUniqueId, init, isBranching, isTrackingEndpoint, requestClose, requestInit, requestStart, requestStop, retrieveComponentState, setContinueOnFail, setIsTrackingEndpoint, setUniqueIdclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitcontinueOnFailure, doService, isBranching, setUniqueIdcreateName, createQualifier, isTrackingEndpointchangeState, requestClose, requestInit, requestStart, requestStop, retrieveComponentStategetUniqueIdclose, initpublic void prepare()
throws CoreException
ComponentLifecycleExtensionprepare in interface ComponentLifecycleExtensionCoreExceptionpublic void closeService()
closeService in class ServiceImppublic void initService()
throws CoreException
initService in class ServiceImpCoreExceptionpublic void start()
throws CoreException
ComponentLifecycle
Once a component is started it should be ready to process messages. In the case of AdaptrisMessageConsumer, calling start
will begin message delivery.
start in interface ComponentLifecyclestart in class ServiceImpCoreException - wrapping any underlying Exceptionspublic void stop()
ComponentLifecycle
A stopped component is not expected to be ready to process messages. In the case of AdaptrisMessageConsumer, calling stop
will pause message delivery. Throwing a RuntimeException may cause unintended consequences
stop in interface ComponentLifecyclestop in class ServiceImpprotected Cache retrieveCache()
public AdaptrisConnection getConnection()
ConnectedServiceAdaptrisConnection to use.getConnection in interface ConnectedServiceAdaptrisConnectionpublic void setConnection(AdaptrisConnection cacheConnection)
setConnection in interface ConnectedServicecacheConnection - the AdaptrisConnection to useCacheConnection,
SharedConnectionpublic <T extends CacheServiceImpl> T withConnection(AdaptrisConnection c)