|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.springframework.jdbc.support.nativejdbc.NativeJdbcExtractorAdapter
org.springframework.jdbc.support.nativejdbc.XAPoolNativeJdbcExtractor
public class XAPoolNativeJdbcExtractor
Implementation of the NativeJdbcExtractor interface for
ObjectWeb's XAPool, as shipped with JOTM and used in JOnAS.
Returns underlying native Connections and native PreparedStatements to
application code instead of XAPool's wrapper implementations; unwraps the
Connection for native Statements and native CallableStatements.
The returned JDBC classes can then safely be cast, e.g. to
oracle.jdbc.OracleConnection.
This NativeJdbcExtractor can be set just to allow working with an XAPool DataSource: If a given object is not an XAPool wrapper, it will be returned as-is.
| Constructor Summary | |
|---|---|
XAPoolNativeJdbcExtractor()
|
|
| Method Summary | |
|---|---|
protected Connection |
doGetNativeConnection(Connection con)
Not able to unwrap: return passed-in Connection. |
PreparedStatement |
getNativePreparedStatement(PreparedStatement ps)
Not able to unwrap: return passed-in PreparedStatement. |
boolean |
isNativeConnectionNecessaryForNativeCallableStatements()
Return true, as CoreCallableStatement does not allow access to the
underlying Connection. |
boolean |
isNativeConnectionNecessaryForNativeStatements()
Return true, as CoreStatement does not allow access to the
underlying Connection. |
| Methods inherited from class org.springframework.jdbc.support.nativejdbc.NativeJdbcExtractorAdapter |
|---|
getNativeCallableStatement, getNativeConnection, getNativeConnectionFromStatement, getNativeResultSet, getNativeStatement, isNativeConnectionNecessaryForNativePreparedStatements |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public XAPoolNativeJdbcExtractor()
| Method Detail |
|---|
public boolean isNativeConnectionNecessaryForNativeStatements()
true, as CoreStatement does not allow access to the
underlying Connection.
isNativeConnectionNecessaryForNativeStatements in interface NativeJdbcExtractorisNativeConnectionNecessaryForNativeStatements in class NativeJdbcExtractorAdapterpublic boolean isNativeConnectionNecessaryForNativeCallableStatements()
true, as CoreCallableStatement does not allow access to the
underlying Connection.
isNativeConnectionNecessaryForNativeCallableStatements in interface NativeJdbcExtractorisNativeConnectionNecessaryForNativeCallableStatements in class NativeJdbcExtractorAdapter
protected Connection doGetNativeConnection(Connection con)
throws SQLException
NativeJdbcExtractorAdapter
doGetNativeConnection in class NativeJdbcExtractorAdapterSQLException
public PreparedStatement getNativePreparedStatement(PreparedStatement ps)
throws SQLException
NativeJdbcExtractorAdapter
getNativePreparedStatement in interface NativeJdbcExtractorgetNativePreparedStatement in class NativeJdbcExtractorAdapterps - the PreparedStatement handle, potentially wrapped by a connection pool
SQLException - if thrown by JDBC methods
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||