|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
com.ibm.as400.access.AS400JDBCXADataSource
The AS400JDBCXADataSource class represents a factory for AS400JDBCXAConnection objects.
This support is only available on the release of the AS/400 that follows V4R5.
The following example creates an AS400JDBCXADataSource object and creates a connection to the database.
// Create an XA data source for making the connection. AS400JDBCXADataSource xaDataSource = new AS400JDBCXADataSource("myAS400"); xaDataSource.setUser("myUser"); xaDataSource.setPassword("myPasswd"); // Get the XAConnection. XAConnection xaConnection = xaDataSource.getXAConnection();
AS400JDBCXAConnection
,
AS400JDBCXAResource
Constructor Summary | |
AS400JDBCXADataSource()
Constructs a default AS400JDBCXADataSource object. |
|
AS400JDBCXADataSource(java.lang.String serverName)
Constructs an AS400JDBCXADataSource with the specified serverName. |
|
AS400JDBCXADataSource(java.lang.String serverName,
java.lang.String user,
java.lang.String password)
Constructs an AS400JDBCXADataSource with the specified signon information. |
|
AS400JDBCXADataSource(java.lang.String serverName,
java.lang.String user,
java.lang.String password,
java.lang.String keyRingName,
java.lang.String keyRingPassword)
Constructs an AS400JDBCXADataSource with the specified signon information to use for SSL communications with the server. |
Method Summary | |
javax.naming.Reference |
getReference()
Returns the Reference object for the data source object. |
javax.sql.XAConnection |
getXAConnection()
Returns an XA connection to the AS/400. |
javax.sql.XAConnection |
getXAConnection(java.lang.String user,
java.lang.String password)
Returns an XA connection to the AS/400. |
Constructor Detail |
public AS400JDBCXADataSource()
public AS400JDBCXADataSource(java.lang.String serverName)
serverName
- The name of the AS/400 server.public AS400JDBCXADataSource(java.lang.String serverName, java.lang.String user, java.lang.String password)
serverName
- The name of the AS/400 server.user
- The user id.password
- The password.public AS400JDBCXADataSource(java.lang.String serverName, java.lang.String user, java.lang.String password, java.lang.String keyRingName, java.lang.String keyRingPassword)
serverName
- The name of the AS/400 server.user
- The user id.password
- The password.keyRingName
- The key ring class name to be used for SSL communications with the server.keyRingPassword
- The password for the key ring class to be used for SSL communications with the server.Method Detail |
public javax.sql.XAConnection getXAConnection() throws java.sql.SQLException
public javax.sql.XAConnection getXAConnection(java.lang.String user, java.lang.String password) throws java.sql.SQLException
user
- The userid for the connection.password
- The password for the connection.public javax.naming.Reference getReference() throws javax.naming.NamingException
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |