|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface IConnectionProfile
The interface used when working with an instance of a connection profile.
Field Summary | |
---|---|
static java.lang.String |
AUTO_CONNECT_PROPERTY_ID
Property ID for profile auto-connect. |
static java.lang.String |
CONNECTED_PROPERTY_ID
Deprecated. use CONNECTION_STATE_PROPERTY_ID |
static int |
CONNECTED_STATE
When the connection profile is in this state, active connections to the server exist. |
static java.lang.String |
CONNECTION_PROFILE_PROPERTY_SET
Property set ID for common connection profile properties |
static java.lang.String |
CONNECTION_STATE_PROPERTY_ID
Property ID for "connection" state. |
static java.lang.String |
DESCRIPTION_PROPERTY_ID
Property ID for profile description. |
static int |
DISCONNECTED_STATE
When the connection profile is in this state, no active connections to the server exist. |
static java.lang.String |
INSTANCE_ID_PROPERTY_ID
Property ID for profile instance ID. |
static java.lang.String |
NAME_PROPERTY_ID
Property ID for profile name. |
static java.lang.String |
TRANSIENT_PROPERTY_ID
Transient marker for profile instance. |
static int |
WORKING_OFFLINE_STATE
When the connection profile is in this state, no active connections to the server exist. |
Method Summary | |
---|---|
void |
addConnectListener(IConnectListener listener)
Deprecated. use IManagedConnection.removeConnectionListener() |
void |
addPropertySetListener(IPropertySetListener listener)
Add property listener to this profile. |
boolean |
arePropertiesComplete()
Returns true if all property sets associated with this profile are complete; false if more information is required (e.g. |
boolean |
arePropertiesComplete(java.lang.String type)
Returns true if the specified property set type associated with this profile is complete; false if more information is required (e.g. |
boolean |
canWorkOffline()
|
org.eclipse.core.runtime.IStatus |
connect()
This method blocks until all registered connect listeners have been notified to open connections. |
void |
connect(org.eclipse.core.runtime.jobs.IJobChangeListener listener)
This method returns immediately after spawning a Job which notifies all registered connect listeners to open connections. |
org.eclipse.core.runtime.IStatus |
connectWithoutJob()
This method blocks until all registered connect listeners have been notified to open connections. |
IConnection |
createConnection(java.lang.String factory)
This method is a shortcut for getProvider()getConnectionFactory(factoryId).createConnection(this). |
IConnection |
createConnection(java.lang.String factoryId,
java.lang.String uid,
java.lang.String pwd)
This method is a shortcut for getProvider()getConnectionFactory(factoryId).createConnection(this,uid,pwd). |
org.eclipse.core.runtime.IStatus |
disconnect()
This method blocks until all registered connect listeners have been notified to close connections. |
void |
disconnect(org.eclipse.core.runtime.jobs.IJobChangeListener listener)
This method returns immediately after spawning a Job which notifies all registered connect listeners to close connections. |
java.util.Properties |
getBaseProperties()
This method returns the properties managed by the base connection profile extension. |
ICategory |
getCategory()
This method is a shortcut for getProvider().getCategory(). |
IConfigurationType |
getConfigurationType()
Deprecated. |
int |
getConnectionState()
|
java.lang.String |
getDescription()
|
java.lang.String |
getInstanceID()
|
IManagedConnection |
getManagedConnection(java.lang.String type)
|
java.lang.String |
getName()
|
IConnectionProfile |
getParentProfile()
This method returns the connection profile that this connection profile derives from. |
java.util.Map |
getProfileExtensions()
This method is a shortcut for getProvider().getProfileExtensions(). |
java.util.Properties |
getProperties(java.lang.String type)
This method returns the properties associated with a connection profile profile extension. |
IConnectionProfileProvider |
getProvider()
Returns the provider responsible for managing this connection profile. |
java.lang.String |
getProviderId()
This method is a shortcut for getProvider().getProviderId(). |
java.lang.String |
getProviderName()
This method is a shortcut for getProvider().getName(). |
boolean |
isAutoConnect()
|
boolean |
isConnected()
Deprecated. Use getConnectionState() |
void |
removeConnectListener(IConnectListener listener)
Deprecated. use IManagedConnection.removeConnectionListener() |
void |
removePropertySetListener(IPropertySetListener listener)
|
org.eclipse.core.runtime.IStatus |
saveWorkOfflineData()
Saves the state of the connection profile for working in an offline mode. |
void |
saveWorkOfflineData(org.eclipse.core.runtime.jobs.IJobChangeListener listener)
Saves the state of the connection profile for working in an offline mode. |
void |
setBaseProperties(java.util.Properties props)
This method sets the properties managed by the base connection profile extension. |
void |
setConnected(boolean connected)
Deprecated. Use one of the connect() methods instead. This method now delegates to connect(). |
void |
setProperties(java.lang.String type,
java.util.Properties props)
This method sets the properties managed by a specific profile extension. |
boolean |
supportsWorkOfflineMode()
|
org.eclipse.core.runtime.IStatus |
workOffline()
This method blocks until all registered connect listeners that support working offline have been notified to restore offline data. |
void |
workOffline(org.eclipse.core.runtime.jobs.IJobChangeListener listener)
This method returns immediately after spawning a Job which notifies all registered connect listeners that support working offline have been notified to restore offline data. |
Field Detail |
---|
static final java.lang.String CONNECTION_PROFILE_PROPERTY_SET
static final java.lang.String CONNECTED_PROPERTY_ID
CONNECTION_STATE_PROPERTY_ID
static final java.lang.String CONNECTION_STATE_PROPERTY_ID
static final java.lang.String NAME_PROPERTY_ID
static final java.lang.String DESCRIPTION_PROPERTY_ID
static final java.lang.String AUTO_CONNECT_PROPERTY_ID
static final java.lang.String INSTANCE_ID_PROPERTY_ID
static final java.lang.String TRANSIENT_PROPERTY_ID
static final int DISCONNECTED_STATE
static final int CONNECTED_STATE
static final int WORKING_OFFLINE_STATE
Method Detail |
---|
java.lang.String getName()
java.lang.String getDescription()
boolean isAutoConnect()
java.lang.String getInstanceID()
IConnectionProfile getParentProfile()
java.util.Properties getBaseProperties()
void setBaseProperties(java.util.Properties props)
props
- the properties to set as the base properties.java.util.Properties getProperties(java.lang.String type)
type
- the type of properties.
void setProperties(java.lang.String type, java.util.Properties props)
type
- the type of properties.props
- the properties to set.boolean arePropertiesComplete()
boolean arePropertiesComplete(java.lang.String type)
type
- the type of properties
void setConnected(boolean connected)
connected
- the connected state.boolean isConnected()
getConnectionState()
int getConnectionState()
DISCONNECTED_STATE
, CONNECTED_STATE
,
WORKING_OFFLINE_STATE
org.eclipse.core.runtime.IStatus connect()
void connect(org.eclipse.core.runtime.jobs.IJobChangeListener listener)
listener
- a job listener that can be used to notify the caller of
the state of the job spawned to open the connections. Can be null.org.eclipse.core.runtime.IStatus connectWithoutJob()
org.eclipse.core.runtime.IStatus disconnect()
void disconnect(org.eclipse.core.runtime.jobs.IJobChangeListener listener)
listener
- a job listener that can be used to notify the caller of
the state of the job spawned to close the connections. Can be
null.org.eclipse.core.runtime.IStatus workOffline()
void workOffline(org.eclipse.core.runtime.jobs.IJobChangeListener listener)
listener
- a job listener that can be used to notify the caller of
the state of the job spawned to restore offline data. Can be null.boolean supportsWorkOfflineMode()
boolean canWorkOffline()
org.eclipse.core.runtime.IStatus saveWorkOfflineData()
void saveWorkOfflineData(org.eclipse.core.runtime.jobs.IJobChangeListener listener)
saveWorkOfflineData()
except that it returns
immediately, without waiting for the save offline data job to complete.
void addConnectListener(IConnectListener listener)
listener
- void removeConnectListener(IConnectListener listener)
listener
- IManagedConnection getManagedConnection(java.lang.String type)
type
- the ID of the connection factory responsible for creating the
connection
void addPropertySetListener(IPropertySetListener listener)
listener
- void removePropertySetListener(IPropertySetListener listener)
listener
- java.lang.String getProviderName()
IConnectionProfileProvider.getConfigurationType()
java.lang.String getProviderId()
ICategory getCategory()
IConnectionProfileProvider.getCategory()
IConfigurationType getConfigurationType()
IConnectionProfileProvider.getConfigurationType()
java.util.Map getProfileExtensions()
IConnectionProfileProvider.getProfileExtensions()
IConnection createConnection(java.lang.String factory)
factory
- the connection factory id
IConnectionFactory.createConnection(IConnectionProfile)
IConnection createConnection(java.lang.String factoryId, java.lang.String uid, java.lang.String pwd)
factoryId
- the connection factory iduid
- the user idpwd
- the user's password
IConnectionFactory.createConnection(IConnectionProfile,String,String)
IConnectionProfileProvider getProvider()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |