|
RSE Release 3.0 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.eclipse.rse.core.subsystems.AbstractDelegatingConnectorService
public abstract class AbstractDelegatingConnectorService
Field Summary | |
---|---|
protected IHost |
_host
|
Fields inherited from interface org.eclipse.rse.core.model.IRSEPersistableContainer |
---|
NO_CHILDREN |
Constructor Summary | |
---|---|
AbstractDelegatingConnectorService(IHost host)
Creates a new delegating connector service for a particular host. |
Method Summary | |
---|---|
void |
acquireCredentials(boolean forcePrompt)
Acquire the credentials for this connector service. |
void |
addCommunicationsListener(ICommunicationsListener listener)
Register a communications listener. |
boolean |
addPropertySet(IPropertySet set)
Adds an existing property set to this container. |
boolean |
addPropertySets(IPropertySet[] sets)
Adds a number of existing property sets to this container. |
void |
clearCredentials()
Clears the credentials held by this service. |
void |
clearPassword(boolean clearDiskCache,
boolean propagate)
Clear password held by this service and optionally clear its persistent form. |
boolean |
commit()
Request a persistence manager to persist this object. |
void |
connect(IProgressMonitor monitor)
Connect to the remote system. |
IPropertySet |
createPropertySet(String name)
Creates a new property set of a particular name in this container. |
IPropertySet |
createPropertySet(String name,
String description)
Creates a new property set of a particular name and description in this container. |
void |
deregisterSubSystem(ISubSystem ss)
Deregister the subsystem. |
void |
disconnect(IProgressMonitor monitor)
Disconnect from the remote system. |
boolean |
getDenyPasswordSave()
Retrieves the value of the "DENY_PASSWORD_SAVE" property of this connector service. |
String |
getDescription()
|
String |
getHomeDirectory()
|
IHost |
getHost()
|
String |
getHostName()
|
String |
getName()
|
IRSEPersistableContainer[] |
getPersistableChildren()
Retrieves the children of this object in the persistence containment hierarchy. |
IRSEPersistableContainer |
getPersistableParent()
Retrieve the parent of this object in the persistence containment hierarchy. |
int |
getPort()
|
ISubSystem |
getPrimarySubSystem()
|
IPropertySet |
getPropertySet(String name)
Retrieves a particular property set by its name. |
IPropertySet[] |
getPropertySets()
Retrieves an array all property sets known to this container. |
abstract IConnectorService |
getRealConnectorService()
|
IServerLauncher |
getRemoteServerLauncher()
|
IServerLauncherProperties |
getRemoteServerLauncherProperties()
Gets the properties associated with a remote server launcher. |
ISubSystem[] |
getSubSystems()
Return all the subsystems that use this connector service |
String |
getTempDirectory()
|
String |
getUserId()
|
String |
getVersionReleaseModification()
|
boolean |
hasPassword(boolean onDisk)
|
boolean |
hasRemoteServerLauncherProperties()
|
boolean |
inheritsCredentials()
Returns true if this system can inherit the credentials of from the other connector services in this host. |
boolean |
isConnected()
|
boolean |
isDirty()
An object is dirty if a change has been made to it that requires it to be persisted. |
boolean |
isServerLaunchTypeEnabled(ISubSystem subsystem,
ServerLaunchType serverLaunchType)
This methods returns the enablement state of a server launch type. |
boolean |
isSuppressed()
|
boolean |
isTainted()
An object is tainted if it contains an object that is dirty somewhere in its containment hierarchy. |
boolean |
isUsingSSL()
|
void |
registerSubSystem(ISubSystem ss)
Adds a subsystem to this connector service. |
void |
removeCommunicationsListener(ICommunicationsListener listener)
Remove a communications listener. |
void |
removePassword()
Causes the persisted password known to this connector service, if any, to be forgotten. |
boolean |
removePropertySet(String name)
Removes a particular property set from this container. |
void |
removeUserId()
Causes the persisted (default) user id known to this connector service, if any, to be forgotten. |
boolean |
requiresPassword()
Test if this connector service requires a password. |
boolean |
requiresUserId()
Test if this connector service requires a user id. |
void |
reset()
Reset after some fundamental change, such as a hostname change. |
void |
savePassword()
Causes the password known to this connector service, if any, to be persisted. |
void |
saveUserId()
Causes the user id known to the connector service, if any, to be persisted. |
int |
setDenyPasswordSave(boolean deny)
Sets the attribute for this connector service instance that denies a password to be saved. |
void |
setDirty(boolean flag)
An object is dirty if a change has been made to it that requires it to be persisted. |
void |
setHost(IHost host)
Sets the host used by this connector service. |
void |
setIsUsingSSL(boolean flag)
|
void |
setPassword(String matchingUserId,
String password,
boolean persist,
boolean propagate)
Sets the password used by this connector service. |
void |
setPort(int port)
Set the port for this connector. |
void |
setRemoteServerLauncherProperties(IServerLauncherProperties value)
Set the properties for the remote server launcher This is an object containing properties used to launch a remote server that communicates with this client. |
void |
setSuppressed(boolean suppressSignonPrompt)
Suppresses the acquisition of a credentials by the connector service. |
void |
setTainted(boolean flag)
Sets the tainted attribute for this object. |
void |
setUserId(String userId)
Set the user id this connector service will use when establishing its connection. |
void |
setWasRestored(boolean flag)
Sets the restored state of the object. |
boolean |
sharesCredentials()
Return true if this system can share it's credentials with other connector services in this host. |
boolean |
supportsPassword()
Determines if this connector service understand the concept of a password. |
boolean |
supportsRemoteServerLaunching()
|
boolean |
supportsServerLaunchProperties()
|
boolean |
supportsUserId()
Reports if this connector service can use a user identifier. |
boolean |
wasRestored()
An object was restored if it originated from a persistent form. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected IHost _host
Constructor Detail |
---|
public AbstractDelegatingConnectorService(IHost host)
host
- The host associated with this connector service.Method Detail |
---|
public abstract IConnectorService getRealConnectorService()
getRealConnectorService
in interface IDelegatingConnectorService
public void addCommunicationsListener(ICommunicationsListener listener)
IConnectorService
addCommunicationsListener
in interface IConnectorService
listener
- a listener for the communications event.public boolean addPropertySet(IPropertySet set)
IPropertySetContainer
addPropertySet
in interface IPropertySetContainer
set
- the property set to be added.
public boolean addPropertySets(IPropertySet[] sets)
IPropertySetContainer
addPropertySets
in interface IPropertySetContainer
sets
- the sets to be added
IPropertySetContainer.addPropertySet(IPropertySet)
public void clearPassword(boolean clearDiskCache, boolean propagate)
IConnectorService
clearPassword
in interface IConnectorService
clearDiskCache
- if true, clears the persistent form of the passwordpropagate
- true if this password should be cleared in related connector services.public void clearCredentials()
IConnectorService
clearCredentials
in interface IConnectorService
public boolean commit()
IRSEPersistableContainer
commit
in interface IRSEPersistableContainer
public void connect(IProgressMonitor monitor) throws Exception
IConnectorService
connect
in interface IConnectorService
monitor
- a monitor for tracking the progress and canceling a
connect operation.
OperationCanceledException
- if the connect was cancelled by the
user
Exception
- if there is a failure connecting. Typically, this will
be a SystemMessageException
.public IPropertySet createPropertySet(String name)
IPropertySetContainer
IRSEPersistableContainer
. The
IRSEPersistableContainer.commit()
method must then be used to
commit any changes into persistent storage.
createPropertySet
in interface IPropertySetContainer
name
- the name of the property set.
public IPropertySet createPropertySet(String name, String description)
IPropertySetContainer
IRSEPersistableContainer
. The
IRSEPersistableContainer.commit()
method must then be used to
commit any changes into persistent storage.
createPropertySet
in interface IPropertySetContainer
name
- the name of the property set.description
- the description (usually already localized) for this
property set.
public void deregisterSubSystem(ISubSystem ss)
IConnectorService
deregisterSubSystem
in interface IConnectorService
ss
- the subsystem to remove from this connector service.public void disconnect(IProgressMonitor monitor) throws Exception
IConnectorService
disconnect
in interface IConnectorService
monitor
- a monitor for tracking the progress and canceling a
disconnect operation.
Exception
- an exception of the disconnect fails. Typically, this
will be a SystemMessageException
.public String getDescription()
getDescription
in interface IRSEModelObject
public String getHomeDirectory()
getHomeDirectory
in interface IConnectorService
public IHost getHost()
getHost
in interface IConnectorService
public String getHostName()
getHostName
in interface IConnectorService
public String getName()
getName
in interface IRSEModelObject
public int getPort()
getPort
in interface IConnectorService
public ISubSystem getPrimarySubSystem()
getPrimarySubSystem
in interface IConnectorService
public IPropertySet getPropertySet(String name)
IPropertySetContainer
getPropertySet
in interface IPropertySetContainer
name
- the name of the property set.
public IPropertySet[] getPropertySets()
IPropertySetContainer
getPropertySets
in interface IPropertySetContainer
public IServerLauncher getRemoteServerLauncher()
getRemoteServerLauncher
in interface IConnectorService
IConnectorService.supportsRemoteServerLaunching()
is true.public IServerLauncherProperties getRemoteServerLauncherProperties()
IConnectorService
getRemoteServerLauncherProperties
in interface IConnectorService
public ISubSystem[] getSubSystems()
IConnectorService
getSubSystems
in interface IConnectorService
public String getTempDirectory()
getTempDirectory
in interface IConnectorService
public String getUserId()
getUserId
in interface IConnectorService
public String getVersionReleaseModification()
getVersionReleaseModification
in interface IConnectorService
public boolean hasPassword(boolean onDisk)
hasPassword
in interface IConnectorService
onDisk
- also check for the persistent form of the password.
public boolean hasRemoteServerLauncherProperties()
hasRemoteServerLauncherProperties
in interface IConnectorService
public boolean inheritsCredentials()
IConnectorService
inheritsCredentials
in interface IConnectorService
public boolean isConnected()
isConnected
in interface IConnectorService
public boolean isDirty()
IRSEPersistableContainer
isDirty
in interface IRSEPersistableContainer
public boolean isServerLaunchTypeEnabled(ISubSystem subsystem, ServerLaunchType serverLaunchType)
IConnectorService
RemoteServerLauncher.enableServerLaunchType(ServerLaunchType, boolean)
has not been
called for this server launch type, then it is enabled by default.
isServerLaunchTypeEnabled
in interface IConnectorService
subsystem
- the subystem for which this may be enabled.serverLaunchType
- the type to check for enabledment.
ServerLaunchType
public boolean isSuppressed()
isSuppressed
in interface IConnectorService
public boolean isUsingSSL()
isUsingSSL
in interface IConnectorService
public void acquireCredentials(boolean forcePrompt) throws OperationCanceledException
IConnectorService
IConnectorService.setSuppressed(boolean)
.
Implementations may retain a remembered credentials or use this to acquire the credentials using some implementation defined means.
acquireCredentials
in interface IConnectorService
forcePrompt
- if true will force the connector service to discard any
remembered value and reacquire the credentials.
OperationCanceledException
- if acquisition of the credentials is
cancelled or is being suppressed.public void registerSubSystem(ISubSystem ss)
IConnectorService
registerSubSystem
in interface IConnectorService
ss
- a subsystem that is using this connector service.public void removeCommunicationsListener(ICommunicationsListener listener)
IConnectorService
removeCommunicationsListener
in interface IConnectorService
listener
- a listener for the communications event.public boolean removePropertySet(String name)
IPropertySetContainer
removePropertySet
in interface IPropertySetContainer
name
- the name of the property set to be removed
public void reset()
IConnectorService
reset
in interface IConnectorService
public void setDirty(boolean flag)
IRSEPersistableContainer
An object is dirty if a change has been made to it that requires it to be persisted. Objects should usually mark themselves dirty when a persistable change is made. However, there may be a need to mark related objects dirty as well.
Persistable changes are:
A rename may also cause a parent to be marked dirty if the parent refers to the child by name.
Setting this value to false should be done only in the persistence manager after the object has been written to the DOM.
Marking an object as dirty must cause it and all of its ancestors in the persistence hierarchy to be marked as tainted.
setDirty
in interface IRSEPersistableContainer
flag
- true if the object must be persisted.public void setHost(IHost host)
IConnectorService
setHost
in interface IConnectorService
host
- the host to be used for this connector servicepublic void setIsUsingSSL(boolean flag)
setIsUsingSSL
in interface IConnectorService
flag
- true if the connector service should attempt to use SSL when
establishing the connection.public void setPassword(String matchingUserId, String password, boolean persist, boolean propagate)
IConnectorService
setPassword
in interface IConnectorService
matchingUserId
- The user id to be associated with this password.password
- the passwordpersist
- true if the password is to be persisted for later use.propagate
- true if this password should be propagated to related connector services.public void setPort(int port)
IConnectorService
setPort
in interface IConnectorService
port
- the IP port used by this connector service.public void setRemoteServerLauncherProperties(IServerLauncherProperties value)
IConnectorService
setRemoteServerLauncherProperties
in interface IConnectorService
value
- the new value of the 'Remote Server Launcher' containment reference.public void setSuppressed(boolean suppressSignonPrompt)
IConnectorService
IConnectorService.acquireCredentials(boolean)
to immediately
throw an InterruptedException.
The intent is to allow tool writers to prevent multiple attempts to acquire credentials during a set period of time. It is the responsibility of the caller to set this value back to false when the tool no longer needs to suppress acquisition credentials.
setSuppressed
in interface IConnectorService
suppressSignonPrompt
- true
if acquisition is to be suppressed.
false
if acquisition is to be allowed.public void setUserId(String userId)
IConnectorService
setUserId
in interface IConnectorService
userId
- the user id string for this connector service.public void setWasRestored(boolean flag)
IRSEPersistableContainer
setWasRestored
in interface IRSEPersistableContainer
flag
- true if the object was restored.public boolean sharesCredentials()
IConnectorService
sharesCredentials
in interface IConnectorService
public boolean supportsPassword()
IConnectorService
supportsPassword
in interface IConnectorService
public boolean supportsRemoteServerLaunching()
supportsRemoteServerLaunching
in interface IConnectorService
public boolean supportsServerLaunchProperties()
supportsServerLaunchProperties
in interface IConnectorService
IConnectorService.supportsRemoteServerLaunching()
is false.public boolean supportsUserId()
IConnectorService
supportsUserId
in interface IConnectorService
public void saveUserId()
IConnectorService
saveUserId
in interface IConnectorService
public void removeUserId()
IConnectorService
removeUserId
in interface IConnectorService
public void savePassword()
IConnectorService
savePassword
in interface IConnectorService
public void removePassword()
IConnectorService
removePassword
in interface IConnectorService
public boolean wasRestored()
IRSEPersistableContainer
wasRestored
in interface IRSEPersistableContainer
public boolean requiresPassword()
IConnectorService
requiresPassword
in interface IConnectorService
public boolean requiresUserId()
IConnectorService
requiresUserId
in interface IConnectorService
public boolean isTainted()
IRSEPersistableContainer
isTainted
in interface IRSEPersistableContainer
public void setTainted(boolean flag)
IRSEPersistableContainer
setTainted
in interface IRSEPersistableContainer
flag
- the tainted state of the object.public IRSEPersistableContainer getPersistableParent()
IRSEPersistableContainer
getPersistableParent
in interface IRSEPersistableContainer
public IRSEPersistableContainer[] getPersistableChildren()
IRSEPersistableContainer
getPersistableChildren
in interface IRSEPersistableContainer
IRSEPersistableContainer.NO_CHILDREN
.public int setDenyPasswordSave(boolean deny)
setDenyPasswordSave
in interface IConnectorService
deny
- If true, forget any saved passwords and do not allow any
others to be saved. If false, allow passwords to be saved in
the keyring.
public boolean getDenyPasswordSave()
getDenyPasswordSave
in interface IConnectorService
|
RSE Release 3.0 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |