public class ConnectionInfo
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
static int |
CONNECTION_TYPE_JDBC |
static int |
CONNECTION_TYPE_JNDI |
Constructor and Description |
---|
ConnectionInfo(java.lang.String sJndiDatasource,
java.lang.String sUser,
java.lang.String sPassword)
Constructs a ConnectionInfo with the specified parameters.
|
ConnectionInfo(java.lang.String sDriver,
java.lang.String sURL,
java.lang.String sUser,
java.lang.String sPassword)
Constructs a ConnectionInfo with the specified parameters.
|
Modifier and Type | Method and Description |
---|---|
int |
getConnectionType()
Get current connection type, which should only return CONNECTION_TYPE_JNDI or CONNECTION_TYPE_JDBC
|
java.lang.String |
getDriver()
Gets the jdbc runtime driver name.
|
java.lang.String |
getJNDIDataSource() |
java.lang.String |
getPassword()
Gets the runtime user's password.
|
java.lang.String |
getURL()
Gets the jdbc runtime URL.
|
java.lang.String |
getUser()
Gets the runtime user name used to connect to the database.
|
public static final int CONNECTION_TYPE_JNDI
public static final int CONNECTION_TYPE_JDBC
public ConnectionInfo(java.lang.String sDriver, java.lang.String sURL, java.lang.String sUser, java.lang.String sPassword)
sDriver
- Name of the driver used to connect to the database.sURL
- A jdbc url.sUser
- User name used to connect to the database.sPassword
- User's password.public ConnectionInfo(java.lang.String sJndiDatasource, java.lang.String sUser, java.lang.String sPassword)
sJndiDatasource
- Name of the JNDI DatasourcesUser
- User name used to connect to the database.sPassword
- User's password.public java.lang.String getDriver()
public java.lang.String getURL()
public java.lang.String getUser()
public java.lang.String getPassword()
public int getConnectionType()
public java.lang.String getJNDIDataSource()