public class ConnectionImpl extends ConnectionBaseImpl implements Connection
| Modifier and Type | Class and Description |
|---|---|
static class |
ConnectionImpl.BrowseFuture |
static class |
ConnectionImpl.WriteAttributesFuture |
static class |
ConnectionImpl.WriteFuture |
connectCallbackHandlerconnectionInformation, executor, statistics| Constructor and Description |
|---|
ConnectionImpl(ConnectionInformation connectionInformation) |
ConnectionImpl(ConnectionInformation connectionInformation,
org.apache.mina.core.service.IoProcessor<org.apache.mina.transport.socket.nio.NioSession> processor)
Create a new connection
|
makeProperties, nextRequest, onConnectionClosed, onConnectionConnected, processCallbackFuture, registerCallbackHandler, sendRequestMessage, setCallbackFactoryaddConnectionStateListener, addPrivilegeListener, connect, connect, disconnect, dispose, firePrivilegeChange, getPrivileges, getSession, getSslSession, getState, handleConnectComplete, isDisposed, messageReceived, onConnectionBound, performClosed, performDisconnected, performOpened, removeConnectionStateListener, removePrivilegeListener, sendMessage, sendMessageChecked, setState, switchStategetConnectionInformation, getSessionProperties, getStatistics, setSessionPropertiesclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitaddConnectionStateListener, addPrivilegeListener, connect, connect, disconnect, dispose, getConnectionInformation, getPrivileges, getSessionProperties, getState, removeConnectionStateListener, removePrivilegeListener, setCallbackFactorypublic ConnectionImpl(ConnectionInformation connectionInformation) throws Exception
Exceptionpublic ConnectionImpl(ConnectionInformation connectionInformation, org.apache.mina.core.service.IoProcessor<org.apache.mina.transport.socket.nio.NioSession> processor) throws Exception
connectionInformation - the information where to connect toprocessor - the socket processor, may be null to use the
defaultException - if anything goes wrongpublic static WriteAttributeResults convertResults(List<AttributeWriteResultEntry> attributeResults)
public void browse(Location location, BrowseOperationCallback callback)
Connectionlocation - The path to browsecallback - The callback that shall receive notifications of the operationpublic NotifyFuture<Entry[]> browse(Location location)
public void write(String itemId, Variant value, OperationParameters operationParameters, WriteOperationCallback callback)
public NotifyFuture<WriteResult> startWrite(String itemId, Variant value, OperationParameters operationParameters, CallbackHandler callbackHandler)
public void writeAttributes(String itemId, Map<String,Variant> attributes, OperationParameters operationParameters, WriteAttributeOperationCallback callback)
public NotifyFuture<WriteAttributeResults> startWriteAttributes(String itemId, Map<String,Variant> attributes, OperationParameters operationParameters, CallbackHandler callbackHandler)
public void subscribeFolder(Location location) throws NoConnectionException, OperationException
public void unsubscribeFolder(Location location) throws NoConnectionException, OperationException
public FolderListener setFolderListener(Location location, FolderListener listener)
Connectionlocation - The location for which to set the listenerlistener - The listener to setnull if there was no
previous listenerpublic void subscribeItem(String itemId) throws NoConnectionException, OperationException
public void unsubscribeItem(String itemId) throws NoConnectionException, OperationException
public ItemUpdateListener setItemUpdateListener(String itemId, ItemUpdateListener listener)
ConnectionitemId - The item for which to set the listenerlistener - The listener to setnull if there was no
previous listenerprotected void handleMessage(Object message)
ClientBaseConnectionNote that the method is called while holding the lock the connection itself.
handleMessage in class ConnectionBaseImplmessage - the received messagepublic ScheduledExecutorService getExecutor()
Connectionnullprotected static Map<String,Variant> makeAttributes(Map<String,Variant> addedOrUpdated, Set<String> removed)
protected Collection<Entry> convert(List<BrowserEntry> addedOrModified)
protected static OperationParameters makeParameters(OperationParameters operationParameters)
Copyright © 2016 Eclipse NeoSCADA Project. All rights reserved.