public class WrapperDataSource extends JBossWrapper implements javax.resource.Referenceable, javax.sql.DataSource, java.io.Serializable
Modifier | Constructor and Description |
---|---|
protected |
WrapperDataSource(BaseWrapperManagedConnectionFactory mcf,
javax.resource.spi.ConnectionManager cm)
Constructor
|
Modifier and Type | Method and Description |
---|---|
protected void |
checkTransactionActive()
Check whether a tranasction is active
|
java.sql.Connection |
getConnection() |
java.sql.Connection |
getConnection(java.lang.String user,
java.lang.String password) |
int |
getLoginTimeout() |
java.io.PrintWriter |
getLogWriter() |
java.util.logging.Logger |
getParentLogger() |
javax.naming.Reference |
getReference() |
protected int |
getTimeLeftBeforeTransactionTimeout()
Get the time left before a transaction timeout
|
void |
setLoginTimeout(int param1) |
void |
setLogWriter(java.io.PrintWriter pw) |
void |
setReference(javax.naming.Reference reference) |
getWrappedObject, isWrapperFor, unwrap
protected WrapperDataSource(BaseWrapperManagedConnectionFactory mcf, javax.resource.spi.ConnectionManager cm)
mcf
- The managed connection factorycm
- The connection managerpublic java.io.PrintWriter getLogWriter() throws java.sql.SQLException
getLogWriter
in interface javax.sql.CommonDataSource
java.sql.SQLException
public void setLogWriter(java.io.PrintWriter pw) throws java.sql.SQLException
setLogWriter
in interface javax.sql.CommonDataSource
java.sql.SQLException
public int getLoginTimeout() throws java.sql.SQLException
getLoginTimeout
in interface javax.sql.CommonDataSource
java.sql.SQLException
public void setLoginTimeout(int param1) throws java.sql.SQLException
setLoginTimeout
in interface javax.sql.CommonDataSource
java.sql.SQLException
public java.util.logging.Logger getParentLogger() throws java.sql.SQLFeatureNotSupportedException
getParentLogger
in interface javax.sql.CommonDataSource
java.sql.SQLFeatureNotSupportedException
public java.sql.Connection getConnection() throws java.sql.SQLException
getConnection
in interface javax.sql.DataSource
java.sql.SQLException
public java.sql.Connection getConnection(java.lang.String user, java.lang.String password) throws java.sql.SQLException
getConnection
in interface javax.sql.DataSource
java.sql.SQLException
public void setReference(javax.naming.Reference reference)
public javax.naming.Reference getReference()
getReference
in interface javax.naming.Referenceable
protected int getTimeLeftBeforeTransactionTimeout() throws java.sql.SQLException
-1
if no timeoutjava.sql.SQLException
- Thrown if an error occursprotected void checkTransactionActive() throws java.sql.SQLException
java.sql.SQLException
- if the transaction is not active, preparing, prepared or committing or
for any error in the transaction managerCopyright © 2013 IronJacamar (http://www.ironjacamar.org)