Class AbstractContainerSelector
- java.lang.Object
-
- org.eclipse.ecf.osgi.services.remoteserviceadmin.AbstractContainerSelector
-
- Direct Known Subclasses:
AbstractConsumerContainerSelector
,AbstractHostContainerSelector
public abstract class AbstractContainerSelector extends Object
Abstract superclass for both host and consumer container selectors...i.e. implementers ofIHostContainerSelector
orIConsumerContainerSelector
.
-
-
Field Summary
Fields Modifier and Type Field Description static IRemoteServiceContainer[]
EMPTY_REMOTE_SERVICE_CONTAINER_ARRAY
-
Constructor Summary
Constructors Constructor Description AbstractContainerSelector()
-
Method Summary
-
-
-
Field Detail
-
EMPTY_REMOTE_SERVICE_CONTAINER_ARRAY
public static final IRemoteServiceContainer[] EMPTY_REMOTE_SERVICE_CONTAINER_ARRAY
-
-
Method Detail
-
getContainerManager
protected IContainerManager getContainerManager()
-
getContainerFactory
protected IContainerFactory getContainerFactory()
-
getContainerTypeDescriptions
protected ContainerTypeDescription[] getContainerTypeDescriptions()
-
getContainers
protected IContainer[] getContainers()
-
hasRemoteServiceContainerAdapter
protected IRemoteServiceContainerAdapter hasRemoteServiceContainerAdapter(IContainer container)
-
getContainerTypeDescription
protected ContainerTypeDescription getContainerTypeDescription(IContainer container)
-
getRemoteServiceContainers
protected IRemoteServiceContainer[] getRemoteServiceContainers(IContainer[] containers)
-
includeContainerWithConnectNamespace
protected boolean includeContainerWithConnectNamespace(IContainer container, String connectNamespaceName)
-
connectContainer
protected void connectContainer(IContainer container, ID connectTargetID, IConnectContext connectContext) throws ContainerConnectException
- Throws:
ContainerConnectException
-
getSupportedConfigTypes
protected String[] getSupportedConfigTypes(ContainerTypeDescription containerTypeDescription)
-
getSupportedIntents
protected String[] getSupportedIntents(ContainerTypeDescription containerTypeDescription)
-
createContainer
protected IContainer createContainer(ServiceReference serviceReference, Map<String,Object> properties, ContainerTypeDescription containerTypeDescription) throws SelectContainerException
- Parameters:
serviceReference
- serviceReferenceproperties
- overriding propertiescontainerTypeDescription
- containerTypeDescription- Returns:
- IContainer created container. Should not be
null
- Throws:
SelectContainerException
- thrown if some create or configure failure- Since:
- 2.0
-
createContainer
protected IContainer createContainer(ServiceReference serviceReference, Map<String,Object> properties, ContainerTypeDescription containerTypeDescription, String[] intents) throws SelectContainerException
- Parameters:
serviceReference
- serviceReferenceproperties
- overriding propertiescontainerTypeDescription
- containerTypeDescriptionintents
- intents- Returns:
- IContainer created container. May be null if instance cannot be created (e.g. because of intent requirements)
- Throws:
SelectContainerException
- thrown if some create or configure failure- Since:
- 4.6
-
getContainerFactoryArguments
protected Object getContainerFactoryArguments(ServiceReference serviceReference, Map<String,Object> properties, ContainerTypeDescription containerTypeDescription)
- Parameters:
serviceReference
- serviceReferenceproperties
- overriding propertiescontainerTypeDescription
- containerTypeDescription- Returns:
- Object container factory arguments to use
- Since:
- 2.0
-
getContainerFactoryArguments
protected Object getContainerFactoryArguments(ServiceReference serviceReference, Map<String,Object> properties, ContainerTypeDescription containerTypeDescription, String[] intents)
- Parameters:
serviceReference
- serviceReferenceproperties
- overriding propertiescontainerTypeDescription
- containerTypeDescriptionintents
- intents- Returns:
- Object container factory arguments to use
- Since:
- 4.6
-
createTargetID
protected ID createTargetID(IContainer container, String target)
-
disconnectContainer
protected void disconnectContainer(IContainer container)
-
createConnectContext
protected IConnectContext createConnectContext(ServiceReference serviceReference, Map<String,Object> properties, IContainer container, Object context)
- Parameters:
serviceReference
- serviceReferenceproperties
- overriding propertiescontainer
- the container to create connect context forcontext
- a possible connect context]- Returns:
- IConnectContext a connect context or null
- Since:
- 2.0
-
matchConnectNamespace
protected boolean matchConnectNamespace(IContainer container, ID endpointID, ID connectTargetID)
-
matchContainerID
protected boolean matchContainerID(IContainer container, ID endpointID)
-
-