Class TopologyManagerImpl
- java.lang.Object
-
- org.eclipse.ecf.osgi.services.remoteserviceadmin.AbstractTopologyManager
-
- org.eclipse.ecf.osgi.services.remoteserviceadmin.TopologyManagerImpl
-
- All Implemented Interfaces:
EndpointEventListener
,EndpointListener
public class TopologyManagerImpl extends AbstractTopologyManager implements EndpointListener, EndpointEventListener
- Since:
- 4.6
-
-
Field Summary
Fields Modifier and Type Field Description static int
STARTUP_WAIT_TIME
-
Fields inherited from class org.eclipse.ecf.osgi.services.remoteserviceadmin.AbstractTopologyManager
SERVICE_EXPORTED_INTERFACES_WILDCARD
-
Fields inherited from interface org.osgi.service.remoteserviceadmin.EndpointEventListener
ENDPOINT_LISTENER_SCOPE
-
Fields inherited from interface org.osgi.service.remoteserviceadmin.EndpointListener
ENDPOINT_LISTENER_SCOPE
-
-
Constructor Summary
Constructors Constructor Description TopologyManagerImpl(BundleContext context)
TopologyManagerImpl(BundleContext context, boolean allowLocalHost, String... otherFilters)
-
Method Summary
-
Methods inherited from class org.eclipse.ecf.osgi.services.remoteserviceadmin.AbstractTopologyManager
advertiseEndpointDescription, advertiseModifyEndpointDescription, close, createISIFFilter, createRSAFilter, getContext, getRemoteServiceAdmin, handleAdvertisingResult, handleECFEndpointAdded, handleECFEndpointModified, handleECFEndpointRemoved, handleInvalidImportRegistration, handleNonECFEndpointAdded, handleNonECFEndpointModified, handleNonECFEndpointRemoved, handleNonECFEndpointRemoved, handleServiceModifying, handleServiceRegistering, handleServiceUnregistering, hasDescription, logError, logError, logError, logWarning, trace, unadvertiseEndpointDescription
-
-
-
-
Constructor Detail
-
TopologyManagerImpl
public TopologyManagerImpl(BundleContext context)
-
TopologyManagerImpl
public TopologyManagerImpl(BundleContext context, boolean allowLocalHost, String... otherFilters)
- Since:
- 4.9
-
-
Method Detail
-
getFrameworkUUID
protected String getFrameworkUUID()
- Overrides:
getFrameworkUUID
in classAbstractTopologyManager
-
handleEvent
protected void handleEvent(ServiceEvent event, Map listeners)
- Overrides:
handleEvent
in classAbstractTopologyManager
- Parameters:
event
- the service eventlisteners
- map of listeners
-
handleRemoteAdminEvent
protected void handleRemoteAdminEvent(RemoteServiceAdminEvent event)
-
endpointChanged
public void endpointChanged(EndpointEvent event, String matchedFilter)
Description copied from interface:EndpointEventListener
Notification that an endpoint has changed. Details of the change is captured in the Endpoint Event provided. This could be that an endpoint was added, removed or modified.- Specified by:
endpointChanged
in interfaceEndpointEventListener
- Parameters:
event
- The event containing the details about the change.matchedFilter
- The filter from theEndpointEventListener.ENDPOINT_LISTENER_SCOPE
that matches (or forEndpointEvent.MODIFIED_ENDMATCH
andEndpointEvent.REMOVED
used to match) the endpoint, must not benull
.
-
handleEndpointAdded
protected void handleEndpointAdded(EndpointDescription endpoint, String matchedFilter)
-
handleOtherFilterEndpointAdded
protected void handleOtherFilterEndpointAdded(EndpointDescription endpoint, String matchedFilter)
- Since:
- 4.9
-
handleEndpointRemoved
protected void handleEndpointRemoved(EndpointDescription endpoint, String matchedFilter)
-
handleOtherFilterEndpointRemoved
protected void handleOtherFilterEndpointRemoved(EndpointDescription endpoint, String matchedFilter)
- Since:
- 4.9
-
convertEndpointDescriptionFromOSGiToECF
protected EndpointDescription convertEndpointDescriptionFromOSGiToECF(EndpointDescription ed)
- Since:
- 4.9
-
handleEndpointModifiedEndmatch
protected void handleEndpointModifiedEndmatch(EndpointDescription endpoint, String matchedFilter)
-
handleOtherFilterEndpointModifiedEndmatch
protected void handleOtherFilterEndpointModifiedEndmatch(EndpointDescription endpoint, String matchedFilter)
- Since:
- 4.9
-
handleEndpointModified
protected void handleEndpointModified(EndpointDescription endpoint, String matchedFilter)
-
handleOtherFilterEndpointModified
protected void handleOtherFilterEndpointModified(EndpointDescription endpoint, String matchedFilter)
- Since:
- 4.9
-
exportRegisteredServices
protected void exportRegisteredServices(String exportRegisteredSvcsFilter)
-
endpointAdded
public void endpointAdded(EndpointDescription endpoint, String matchedFilter)
Description copied from interface:EndpointListener
Register an endpoint with this listener. If the endpoint matches one of the filters registered with theEndpointListener.ENDPOINT_LISTENER_SCOPE
service property then this filter should be given as thematchedFilter
parameter. When this service is first registered or it is modified, it should receive all known endpoints matching the filter.- Specified by:
endpointAdded
in interfaceEndpointListener
- Parameters:
endpoint
- The Endpoint Description to be publishedmatchedFilter
- The filter from theEndpointListener.ENDPOINT_LISTENER_SCOPE
that matched the endpoint, must not benull
.
-
endpointRemoved
public void endpointRemoved(EndpointDescription endpoint, String matchedFilter)
Description copied from interface:EndpointListener
Remove the registration of an endpoint. If an endpoint that was registered with theEndpointListener.endpointAdded(EndpointDescription, String)
method is no longer available then this method should be called. This will remove the endpoint from the listener. It is not necessary to remove endpoints when the service is unregistered or modified in such a way that not all endpoints match the interest filter anymore.- Specified by:
endpointRemoved
in interfaceEndpointListener
- Parameters:
endpoint
- The Endpoint Description that is no longer valid.matchedFilter
- The filter from theEndpointListener.ENDPOINT_LISTENER_SCOPE
that matched the endpoint, must not benull
.
-
-