getConnection():
getConnection(ConnectionSpec) must be able to
produce a valid connection. If not null, the
connection must be a valid one and proceed to use
the connection. getConnection(Connection): A null
connection can be returned even if a non-null
connection is provided. If not null, the
connection must be a valid one and proceed to use
the connection. getConnection(ConnectionSpec): A
null connection can be returned even if a non-null
connection is provided. If not null, the
connection must be a valid one and proceed to use
the connection.
- Author:
- JSR-73 Java Data Mining Expert Group
- See Also:
Factory
getConnection
public Connection getConnection()
throws JDMException
- Gets a connection to a DME instance. This
getConnection variant should be used when a JDM client wants the container to manage DME sign-on.
- Returns:
- Connection
- Throws:
JDMException
getConnection
public Connection getConnection(javax.resource.cci.Connection connection)
throws JDMException
- Creates and returns a
Connection from the specified JCX connection. (The parameter type is javax.resource.cci.Connection.)
- Parameters:
connection -
- Returns:
- Connection
- Throws:
JDMException
getConnection
public Connection getConnection(ConnectionSpec spec)
throws JDMException
- Gets a connection to a DME instance. A JDM client needs to pass security information such as user name and password through the ConnectionSpec instance.
It is important to note that the properties passed through the
getConnection method should be client-specific (example: username, password, language).
- Parameters:
spec - The specification of the connection to be created.
- Returns:
- Connection
- Throws:
JDMException
getConnectionSpec
public ConnectionSpec getConnectionSpec()
- Creates a connection specification to be passed into
getConnection(ConnectionSpec).
- Returns:
- ConnectionSpec
supportsCapability
public boolean supportsCapability(ConnectionCapability capability)
throws JDMException
- Returns true if the specified capability is supported by the implementation. Returns false otherwise.
- Parameters:
capability -
- Returns:
- boolean
- Throws:
JDMException