org.eclipse.ecf.provider.datashare
Class DatashareContainer
java.lang.Object
org.eclipse.ecf.core.AbstractContainer
org.eclipse.ecf.provider.generic.SOContainer
org.eclipse.ecf.provider.generic.ClientSOContainer
org.eclipse.ecf.provider.generic.TCPClientSOContainer
org.eclipse.ecf.provider.datashare.DatashareContainer
- All Implemented Interfaces:
- org.eclipse.core.runtime.IAdaptable, IContainer, IIdentifiable, IReliableContainer, ISharedObjectContainer, ISharedObjectContainerClient, IAbstractChannelContainerAdapter, IChannelContainerAdapter
public class DatashareContainer
- extends TCPClientSOContainer
- implements IChannelContainerAdapter
Fields inherited from class org.eclipse.ecf.provider.generic.SOContainer |
config, DEFAULT_OBJECT_ARG_KEY, DEFAULT_OBJECT_ARGTYPES_KEY, groupManager, isClosing, loadingThreadGroup, policy, receiver, sharedObjectManager, sharedObjectMessageSerializer, sharedObjectThreadGroup |
Methods inherited from class org.eclipse.ecf.provider.generic.ClientSOContainer |
connect, createAuthorizationCallbacks, disconnect, disconnect, dispose, forwardExcluding, forwardExcluding, forwardToRemote, getConnectData, getConnectedID, getConnection, getConnectLock, getIDForConnection, getLeaveData, handleConnectResponse, handleLeave, handleLeaveGroupMessage, handleViewChangeMessage, isConnected, isConnecting, isGroupManager, processAsynch, processDisconnect, processSynch, queueContainerMessage, sendCreate, sendCreateMsg, sendCreateResponse, sendCreateResponseSharedObjectMessage, sendCreateSharedObjectMessage, sendDispose, sendDisposeSharedObjectMessage, sendMessage, sendMessage, sendSharedObjectMessage, setConnectInitiatorPolicy |
Methods inherited from class org.eclipse.ecf.provider.generic.SOContainer |
addNewRemoteMember, addSharedObject0, addSharedObjectAndWait, addSharedObjectWrapper, addToLoading, checkRemoteCreate, createContainerPropertiesForSharedObject, createRemoteSharedObjectConfig, createRemoteSharedObjectContext, createRemoteSharedObjectWrapper, createSharedObjectConfig, createSharedObjectContext, createSharedObjectWrapper, debug, defaultDeserializeSharedObjectMessage, defaultSerializeSharedObjectMessage, deserializeContainerMessage, deserializeSharedObjectMessage, destroySharedObject, disconnect, fireDelegateContainerEvent, forward, getAdapter, getArgsFromProperties, getArgTypesFromProperties, getClassLoaderForContainer, getClassLoaderForSharedObject, getConfig, getConnectNamespace, getGroupMemberIDs, getGroupMembershipLock, getID, getMaxGroupMembers, getNewSharedObjectThread, getNextSequenceNumber, getOtherMemberIDs, getReceiver, getSharedObject, getSharedObjectIDs, getSharedObjectManager, getSharedObjectMessageSerializer, getSharedObjectWrapper, handleAsynchIOException, handleCreateMessage, handleCreateResponseMessage, handleSharedObjectDisposeMessage, handleSharedObjectMessage, handleUndeliveredSharedObjectMessage, handleUnidentifiedMessage, isClosing, load, moveFromLoadingToActive, notifySharedObjectActivated, notifySharedObjectDeactivated, printToSystemError, removeFromLoading, removeRemoteMember, removeSharedObject, serialize, serializeSharedObjectMessage, setMaxGroupMembers, setRemoteAddPolicy, setSharedObjectMessageSerializer, traceStack, validateContainerMessage, verifySharedObjectMessageTarget, verifyToIDForSharedObjectMessage |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.eclipse.core.runtime.IAdaptable |
getAdapter |
DEFAULT_CONTAINER_KEEP_ALIVE
protected static final int DEFAULT_CONTAINER_KEEP_ALIVE
- See Also:
- Constant Field Values
DEFAULT_TRANSACTION_WAIT
protected static final int DEFAULT_TRANSACTION_WAIT
- See Also:
- Constant Field Values
adapter
protected DatashareContainerAdapter adapter
DatashareContainer
public DatashareContainer(ISharedObjectContainerConfig config)
createChannel
public IChannel createChannel(ID newID,
IChannelListener listener,
java.util.Map properties)
throws ECFException
- Description copied from interface:
IChannelContainerAdapter
- Create a new channel within this container
- Specified by:
createChannel
in interface IChannelContainerAdapter
- Parameters:
newID
- the ID of the new channel. Must not be null
.listener
- a listener for receiving messages from remotes for this
channel. May be null
if no listener is to be
notified.properties
- a Map of properties to provide to the channel. May be
null
.
- Returns:
- IChannel the new IChannel instance
- Throws:
ECFException
- if some problem creating IChannel instance
createChannel
public IChannel createChannel(IChannelConfig newChannelConfig)
throws ECFException
- Description copied from interface:
IChannelContainerAdapter
- Create a new channel within this container
- Specified by:
createChannel
in interface IChannelContainerAdapter
- Parameters:
newChannelConfig
- the configuration for the newly created channel. Must not be
null
.
- Returns:
- IChannel the new IChannel instance. Will not be
null
.
- Throws:
ECFException
- if some problem creating IChannel instance
getChannel
public IChannel getChannel(ID channelID)
- Description copied from interface:
IAbstractChannelContainerAdapter
- Get IChannel with given channelID.
- Specified by:
getChannel
in interface IAbstractChannelContainerAdapter
- Parameters:
channelID
- the ID of the channel to get. Must not be null
.
- Returns:
- IChannel of channel within container with given ID. Returns
null
if channel not found.
removeChannel
public boolean removeChannel(ID channelID)
- Description copied from interface:
IAbstractChannelContainerAdapter
- Remove channel with given ID. If the channel is found in the container, the
enclosing container will call
IAbstractChannel.dispose()
to dispose the channel
before returning from this method.
- Specified by:
removeChannel
in interface IAbstractChannelContainerAdapter
- Parameters:
channelID
- the ID of the channel to remove within this container. Must
not be null
.
- Returns:
- true if channel found and Removed. False if channel not found
within container.
getChannelNamespace
public Namespace getChannelNamespace()
- Description copied from interface:
IAbstractChannelContainerAdapter
- Get expected Namespace for channel ID creation
- Specified by:
getChannelNamespace
in interface IAbstractChannelContainerAdapter
- Returns:
- Namespace that can be used to create channel ID instances for
this channel container. Will not be
null
.
addListener
public void addListener(IChannelContainerListener listener)
- Description copied from interface:
IAbstractChannelContainerAdapter
- Add listener for IChannelContainerAdapter events.
- Specified by:
addListener
in interface IAbstractChannelContainerAdapter
- Parameters:
listener
- to be added. Must not be null
.
removeListener
public void removeListener(IChannelContainerListener listener)
- Description copied from interface:
IAbstractChannelContainerAdapter
- Remove listener for IChannelContainerAdapter events
- Specified by:
removeListener
in interface IAbstractChannelContainerAdapter
- Parameters:
listener
- to be removed. Must not be null
.