public abstract class AbstractAggreGateDeviceController<D extends AggreGateDevice,C extends RemoteContextManager> extends AbstractDeviceController<IncomingAggreGateCommand,OutgoingAggreGateCommand> implements AggreGateDeviceController<IncomingAggreGateCommand,OutgoingAggreGateCommand>
| Modifier and Type | Field and Description |
|---|---|
protected CompressedCommandWriter<OutgoingAggreGateCommand> |
commandWriter |
static java.lang.String |
FLAG_NO_REPLY |
| Constructor and Description |
|---|
AbstractAggreGateDeviceController(D device,
org.apache.log4j.Logger logger,
int maxEventQueueLength) |
AbstractAggreGateDeviceController(D device,
org.apache.log4j.Logger logger,
int maxEventQueueLength,
boolean json) |
checkAndConnect, connect, disconnect, getActiveCommands, getCommandParser, getCommandTimeout, getLogger, getStatistics, isActive, isConnected, isLoggedIn, login, loginImpl, newDataReceived, resetCommandTimeouts, send, sendCommand, setCommandTimeout, setConnected, setLoggedIn, setResetTimeoutsOnData, startCommandProcessorclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitconnect, disconnect, getActiveCommands, getStatistics, isActive, login, sendCommandpublic static final java.lang.String FLAG_NO_REPLY
protected final CompressedCommandWriter<OutgoingAggreGateCommand> commandWriter
public AbstractAggreGateDeviceController(D device, org.apache.log4j.Logger logger, int maxEventQueueLength)
public AbstractAggreGateDeviceController(D device, org.apache.log4j.Logger logger, int maxEventQueueLength, boolean json)
public C getContextManager()
getContextManager in interface RemoteConnectorpublic void setContextManager(C contextManager)
public void setDevice(D device)
public D getDevice()
getDevice in interface AggreGateDeviceController<IncomingAggreGateCommand,OutgoingAggreGateCommand>public CallerController getCallerController()
getCallerController in interface RemoteConnectorprotected void setCallerController(CallerController callerController)
public FormatCache getFormatCache()
public void setFormatCache(FormatCache cache)
public UserSettings getSettings()
getSettings in interface RemoteConnectorpublic ClassicEncodingSettings createClassicEncodingSettings(boolean forSending)
protected void setAvoidSendingFormats(boolean avoidSendingFormats)
public boolean isAvoidSendingFormats()
protected boolean connectImpl()
throws DisconnectionException,
java.io.IOException,
java.lang.InterruptedException,
RemoteDeviceErrorException,
ContextException
connectImpl in class AbstractDeviceController<IncomingAggreGateCommand,OutgoingAggreGateCommand>DisconnectionExceptionjava.io.IOExceptionjava.lang.InterruptedExceptionRemoteDeviceErrorExceptionContextExceptionpublic abstract void start()
throws java.io.IOException,
java.lang.InterruptedException,
ContextException,
RemoteDeviceErrorException
start in interface AggreGateDeviceController<IncomingAggreGateCommand,OutgoingAggreGateCommand>java.io.IOExceptionjava.lang.InterruptedExceptionContextExceptionRemoteDeviceErrorExceptionpublic void destroy()
public void addDisconnectListener(AbstractAggreGateDeviceControllerDisconnectListener disconnectListener)
protected void disconnectImpl()
disconnectImpl in class AbstractDeviceController<IncomingAggreGateCommand,OutgoingAggreGateCommand>protected java.util.List<ProxyContext> getProxyContexts(java.lang.String path)
protected java.util.concurrent.ExecutorService getEventPreprocessor()
public IncomingAggreGateCommand sendCommandAndCheckReplyCode(OutgoingAggreGateCommand cmd) throws DisconnectionException, ContextException, java.io.IOException, java.lang.InterruptedException, RemoteDeviceErrorException
DisconnectionExceptionContextExceptionjava.io.IOExceptionjava.lang.InterruptedExceptionRemoteDeviceErrorExceptionprotected void processAsyncCommand(IncomingAggreGateCommand cmd)
processAsyncCommand in class AbstractDeviceController<IncomingAggreGateCommand,OutgoingAggreGateCommand>protected void confirmEvent(Context con, EventDefinition def, Event event) throws ContextException
ContextExceptionprotected void setCommandParser(CommandParser commandBuffer)
setCommandParser in class AbstractDeviceController<IncomingAggreGateCommand,OutgoingAggreGateCommand>public java.lang.String toString()
toString in class java.lang.Objectpublic DataTable callRemoteFunction(java.lang.String context, java.lang.String name, TableFormat outputFormat, DataTable parameters, java.lang.String queueName) throws ContextException
ContextExceptionpublic DataTable callRemoteFunction(java.lang.String context, java.lang.String name, TableFormat outputFormat, DataTable parameters, java.lang.String queueName, boolean isReplyRequired) throws ContextException
ContextExceptionprotected DataTable decodeRemoteDataTable(TableFormat format, java.lang.String encodedReply) throws DataTableException
DataTableExceptionpublic boolean isUsesCompression()
public void setUsesCompression(boolean usesCompression)
public ProtocolVersion getProtocolVersion()
public int getEventQueueLength()
public int getRejectedEvents()
public ProtocolCommandBuilder getCommandBuilder()
public boolean isPropagateUnifiedSearchRequests()