org.eclipse.ecf.osgi.services.remoteserviceadmin
Class DiscoveredEndpointDescriptionFactory
java.lang.Object
org.eclipse.ecf.osgi.services.remoteserviceadmin.AbstractMetadataFactory
org.eclipse.ecf.osgi.services.remoteserviceadmin.DiscoveredEndpointDescriptionFactory
- All Implemented Interfaces:
- IDiscoveredEndpointDescriptionFactory
public class DiscoveredEndpointDescriptionFactory
- extends AbstractMetadataFactory
- implements IDiscoveredEndpointDescriptionFactory
Default implementation of IDiscoveredEndpointDescriptionFactory
service.
- See Also:
IDiscoveredEndpointDescriptionFactory
Methods inherited from class org.eclipse.ecf.osgi.services.remoteserviceadmin.AbstractMetadataFactory |
decodeEndpointDescription, decodeList, decodeLong, decodeNonStandardServiceProperties, decodeOSGiProperties, decodeString, encodeList, encodeLong, encodeNonStandardServiceProperties, encodeOSGiServiceProperties, encodeServiceProperties, encodeString, logError, logWarning |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
discoveredEndpointDescriptions
protected java.util.List<DiscoveredEndpointDescription> discoveredEndpointDescriptions
DiscoveredEndpointDescriptionFactory
public DiscoveredEndpointDescriptionFactory()
createDiscoveredEndpointDescription
public DiscoveredEndpointDescription createDiscoveredEndpointDescription(IDiscoveryLocator locator,
IServiceInfo discoveredServiceInfo)
- Description copied from interface:
IDiscoveredEndpointDescriptionFactory
- Create an EndpointDescription for a discovered remote service.
Implementers of this factory service may return the type of
EndpointDescription appropriate for the associated distribution system
(e.g. ECFEndpointDescription). Implementers should return
null
if no notification should occur.
- Specified by:
createDiscoveredEndpointDescription
in interface IDiscoveredEndpointDescriptionFactory
- Parameters:
locator
- the locator responsible for the discoveredServiceInfo. Must
not be null
.discoveredServiceInfo
- the discovered service info. Must not be null
.
- Returns:
- DiscoveredEndpointDescription that will be used to notify
EndpointListeners about a new EndpointDescription. If
null
is returned, no notification should be
performed by the calling code.
removeDiscoveredEndpointDescription
public DiscoveredEndpointDescription removeDiscoveredEndpointDescription(IDiscoveryLocator locator,
IServiceID serviceID)
- Description copied from interface:
IDiscoveredEndpointDescriptionFactory
- Remove an EndpointDescription for a previously discovered remote service.
Implementers of this factory service may return the type of
EndpointDescription appropriate for the associated distribution system
(e.g. ECFEndpointDescription). Implementers should return
null
if no notification should occur.
- Specified by:
removeDiscoveredEndpointDescription
in interface IDiscoveredEndpointDescriptionFactory
- Parameters:
locator
- the locator responsible for the discoveredServiceInfo. Must
not be null
.
- Returns:
- EndpointDescription that will be used to notify EndpointListeners
about an undiscovered EndpointDescription. If
null
is returned, no notification should be performed by the calling
code.
createEndpointDescription
protected org.osgi.service.remoteserviceadmin.EndpointDescription createEndpointDescription(IDiscoveryLocator locator,
IServiceInfo discoveredServiceInfo)
createDiscoveredEndpointDescription
protected DiscoveredEndpointDescription createDiscoveredEndpointDescription(IDiscoveryLocator locator,
IServiceInfo discoveredServiceInfo,
org.osgi.service.remoteserviceadmin.EndpointDescription endpointDescription)
close
public void close()
- Overrides:
close
in class AbstractMetadataFactory
removeDiscoveredEndpointDescription
public boolean removeDiscoveredEndpointDescription(org.osgi.service.remoteserviceadmin.EndpointDescription endpointDescription)
- Description copied from interface:
IDiscoveredEndpointDescriptionFactory
- Remove the DiscoveredEndpointDescription associated with the given
endpointDescription.
- Specified by:
removeDiscoveredEndpointDescription
in interface IDiscoveredEndpointDescriptionFactory
- Parameters:
endpointDescription
- that was previously associated with a
DiscoveredEndpointDescription (via
IDiscoveredEndpointDescriptionFactory.createDiscoveredEndpointDescription(IDiscoveryLocator, IServiceInfo)
to be removed. Must not be null
.
- Returns:
true
if actually removed, false
if
nothing was removed.
removeAllDiscoveredEndpointDescriptions
public void removeAllDiscoveredEndpointDescriptions()
- Description copied from interface:
IDiscoveredEndpointDescriptionFactory
- Remove all DiscoveredEndpointDescription from this factory.
- Specified by:
removeAllDiscoveredEndpointDescriptions
in interface IDiscoveredEndpointDescriptionFactory