public class RemoteServicesManager extends java.lang.Object implements IRemoteServicesManager
Constructor and Description |
---|
RemoteServicesManager() |
Modifier and Type | Method and Description |
---|---|
void |
addRemoteConnectionChangeListener(IRemoteConnectionChangeListener listener)
Add a global connection change listener that receives events for all connections.
|
void |
fireRemoteConnectionChangeEvent(RemoteConnectionChangeEvent event)
Used by connections and other components to notify the global connection
change listeners of events.
|
java.util.List<IRemoteConnectionType> |
getAllConnectionTypes()
Returns the list of all connection types including the local services.
|
java.util.List<IRemoteConnection> |
getAllRemoteConnections()
Returns the list of all known remote connections.
|
IRemoteConnectionType |
getConnectionType(java.lang.String id)
Get the connection type identified by the id
|
IRemoteConnectionType |
getConnectionType(java.net.URI uri)
Get the connection type that provides connections to locations identified by
the URI.
|
java.util.List<IRemoteConnectionType> |
getConnectionTypesByService(java.lang.Class<? extends IRemoteConnectionType.Service>... services)
Returns the list of all connection types that provide specific services.
|
java.util.List<IRemoteConnectionType> |
getConnectionTypesSupporting(java.lang.Class<? extends IRemoteConnection.Service>... services)
Returns the list of all connection types that support connections that provide specific services.
|
IRemoteConnectionType |
getLocalConnectionType()
Return the connection type used to access local resources.
|
org.osgi.service.prefs.Preferences |
getPreferenceNode() |
java.util.List<IRemoteConnectionType> |
getRemoteConnectionTypes()
Returns the list of connection types except for the local connection type.
|
org.eclipse.equinox.security.storage.ISecurePreferences |
getSecurePreferenceNode() |
protected void |
init()
Loads up the services extensions and then loads up the persisted connections.
|
void |
removeRemoteConnectionChangeListener(IRemoteConnectionChangeListener listener)
Remove the global connection change listener.
|
protected void init()
public org.osgi.service.prefs.Preferences getPreferenceNode()
public org.eclipse.equinox.security.storage.ISecurePreferences getSecurePreferenceNode()
public IRemoteConnectionType getConnectionType(java.lang.String id)
IRemoteServicesManager
getConnectionType
in interface IRemoteServicesManager
id
- id of the connection typepublic IRemoteConnectionType getConnectionType(java.net.URI uri)
IRemoteServicesManager
getConnectionType
in interface IRemoteServicesManager
uri
- uri of locations to be accessedpublic IRemoteConnectionType getLocalConnectionType()
IRemoteServicesManager
getLocalConnectionType
in interface IRemoteServicesManager
public java.util.List<IRemoteConnectionType> getAllConnectionTypes()
IRemoteServicesManager
getAllConnectionTypes
in interface IRemoteServicesManager
@SafeVarargs public final java.util.List<IRemoteConnectionType> getConnectionTypesSupporting(java.lang.Class<? extends IRemoteConnection.Service>... services)
IRemoteServicesManager
getConnectionTypesSupporting
in interface IRemoteServicesManager
services
- services provided by connections supported by this connection type@SafeVarargs public final java.util.List<IRemoteConnectionType> getConnectionTypesByService(java.lang.Class<? extends IRemoteConnectionType.Service>... services)
IRemoteServicesManager
getConnectionTypesByService
in interface IRemoteServicesManager
services
- services provided by this connection typepublic java.util.List<IRemoteConnectionType> getRemoteConnectionTypes()
IRemoteServicesManager
getRemoteConnectionTypes
in interface IRemoteServicesManager
public java.util.List<IRemoteConnection> getAllRemoteConnections()
IRemoteServicesManager
getAllRemoteConnections
in interface IRemoteServicesManager
public void addRemoteConnectionChangeListener(IRemoteConnectionChangeListener listener)
IRemoteServicesManager
addRemoteConnectionChangeListener
in interface IRemoteServicesManager
listener
- global connection change listener to be addedpublic void removeRemoteConnectionChangeListener(IRemoteConnectionChangeListener listener)
IRemoteServicesManager
removeRemoteConnectionChangeListener
in interface IRemoteServicesManager
listener
- global connection change listener to be removedpublic void fireRemoteConnectionChangeEvent(RemoteConnectionChangeEvent event)
IRemoteServicesManager
fireRemoteConnectionChangeEvent
in interface IRemoteServicesManager
event
- connection change event