oracle.jdbc
Class OracleConnectionWrapper
java.lang.Object
|
+--oracle.jdbc.OracleConnectionWrapper
- public class OracleConnectionWrapper
- extends java.lang.Object
- implements OracleConnection
A simple implementation of a connection wrapper which may be nested to any depth.
Method Summary |
java.sql.Connection |
_getPC()
|
void |
archive(int mode,
int aseq,
java.lang.String acstext)
|
void |
assertComplete()
|
void |
clearWarnings()
|
void |
close()
|
void |
commit()
|
java.sql.Statement |
createStatement()
|
java.sql.Statement |
createStatement(int resultSetType,
int resultSetConcurrency)
|
java.sql.Statement |
createStatement(int resultSetType,
int resultSetConcurrency,
int resultSetHoldability)
|
boolean |
getAutoClose()
|
boolean |
getAutoCommit()
|
java.sql.CallableStatement |
getCallWithKey(java.lang.String key)
|
java.lang.String |
getCatalog()
|
boolean |
getCreateStatementAsRefCursor()
|
int |
getDefaultExecuteBatch()
|
int |
getDefaultRowPrefetch()
|
java.lang.Object |
getDescriptor(java.lang.String sql_name)
|
boolean |
getExplicitCachingEnabled()
|
int |
getHoldability()
|
boolean |
getImplicitCachingEnabled()
|
boolean |
getIncludeSynonyms()
|
java.lang.Object |
getJavaObject(java.lang.String sql_name)
|
java.sql.DatabaseMetaData |
getMetaData()
|
java.util.Properties |
getProperties()
|
boolean |
getRemarksReporting()
|
boolean |
getRestrictGetTables()
|
java.lang.String |
getSessionTimeZone()
|
java.lang.String |
getSQLType(java.lang.Object obj)
|
int |
getStatementCacheSize()
|
java.sql.PreparedStatement |
getStatementWithKey(java.lang.String key)
|
int |
getStmtCacheSize()
|
short |
getStructAttrCsId()
|
boolean |
getSynchronousMode()
|
int |
getTransactionIsolation()
|
java.util.Map |
getTypeMap()
|
java.lang.String |
getUserName()
|
boolean |
getUsingXAFlag()
|
java.sql.SQLWarning |
getWarnings()
|
boolean |
getXAErrorFlag()
|
boolean |
isClosed()
|
boolean |
isLogicalConnection()
|
boolean |
isReadOnly()
|
java.lang.String |
nativeSQL(java.lang.String sql)
|
java.lang.Object |
openJoltConnection(java.lang.String apiName,
short major,
short minor)
|
void |
oracleReleaseSavepoint(OracleSavepoint savepoint)
|
void |
oracleRollback(OracleSavepoint savepoint)
|
OracleSavepoint |
oracleSetSavepoint()
|
OracleSavepoint |
oracleSetSavepoint(java.lang.String name)
|
int |
pingDatabase(int timeOut)
|
java.sql.CallableStatement |
prepareCall(java.lang.String sql)
|
java.sql.CallableStatement |
prepareCall(java.lang.String sql,
int resultSetType,
int resultSetConcurrency)
|
java.sql.CallableStatement |
prepareCall(java.lang.String sql,
int resultSetType,
int resultSetConcurrency,
int resultSetHoldability)
|
java.sql.CallableStatement |
prepareCallWithKey(java.lang.String key)
|
java.sql.PreparedStatement |
prepareStatement(java.lang.String sql)
|
java.sql.PreparedStatement |
prepareStatement(java.lang.String sql,
int autoGeneratedKeys)
|
java.sql.PreparedStatement |
prepareStatement(java.lang.String sql,
int[] columnIndexes)
|
java.sql.PreparedStatement |
prepareStatement(java.lang.String sql,
int resultSetType,
int resultSetConcurrency)
|
java.sql.PreparedStatement |
prepareStatement(java.lang.String sql,
int resultSetType,
int resultSetConcurrency,
int resultSetHoldability)
|
java.sql.PreparedStatement |
prepareStatement(java.lang.String sql,
java.lang.String[] columnNames)
|
java.sql.PreparedStatement |
prepareStatementWithKey(java.lang.String key)
|
void |
purgeExplicitCache()
|
void |
purgeImplicitCache()
|
void |
putDescriptor(java.lang.String sql_name,
java.lang.Object desc)
|
void |
registerApiDescription(java.lang.String apiName,
short major,
short minor,
java.lang.String className)
|
void |
registerSQLType(java.lang.String sql_name,
java.lang.Class java_class)
|
void |
registerSQLType(java.lang.String sql_name,
java.lang.String java_class_name)
|
void |
registerTAFCallback(OracleOCIFailover cbk,
java.lang.Object obj)
|
void |
releaseSavepoint(java.sql.Savepoint savepoint)
|
void |
rollback()
|
void |
rollback(java.sql.Savepoint savepoint)
|
void |
setAutoClose(boolean autoClose)
|
void |
setAutoCommit(boolean autoCommit)
|
void |
setCatalog(java.lang.String catalog)
|
void |
setCreateStatementAsRefCursor(boolean value)
|
void |
setDefaultExecuteBatch(int batch)
|
void |
setDefaultRowPrefetch(int value)
|
void |
setExplicitCachingEnabled(boolean cache)
|
void |
setHoldability(int holdability)
|
void |
setImplicitCachingEnabled(boolean cache)
|
void |
setIncludeSynonyms(boolean synonyms)
|
void |
setReadOnly(boolean readOnly)
|
void |
setRemarksReporting(boolean reportRemarks)
|
void |
setRestrictGetTables(boolean restrict)
|
java.sql.Savepoint |
setSavepoint()
|
java.sql.Savepoint |
setSavepoint(java.lang.String name)
|
void |
setSessionTimeZone(java.lang.String regionName)
|
void |
setStatementCacheSize(int size)
|
void |
setStmtCacheSize(int size)
|
void |
setStmtCacheSize(int size,
boolean clearMetaData)
|
void |
setSynchronousMode(boolean isSynchronous)
|
void |
setTransactionIsolation(int level)
|
void |
setTypeMap(java.util.Map map)
|
void |
setUsingXAFlag(boolean value)
|
void |
setWrapper(OracleConnection wrapper)
Set a connection wrapper as the wrapper of this connection. |
void |
setXAErrorFlag(boolean value)
|
void |
shutdown(int mode)
|
void |
startup(java.lang.String startup_str,
int mode)
|
OracleConnection |
unwrap()
Unwrap one level. |
Methods inherited from class java.lang.Object |
equals,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
OracleConnectionWrapper
public OracleConnectionWrapper(OracleConnection toBeWrapped)
- Construct an instace which wraps the arguement
unwrap
public OracleConnection unwrap()
- Unwrap one level.
Returns the connection within this wrapper.
- Specified by:
- unwrap in interface OracleConnection
setWrapper
public void setWrapper(OracleConnection wrapper)
- Set a connection wrapper as the wrapper of this connection.
Recursively sets the wrapper to the lowest level.
Thus the physical connection will always know its outermost wrapper
The recursion is terminated by the method in oracle.jdbc.driver.OracleConnction
which stores its argument.
- Specified by:
- setWrapper in interface OracleConnection
createStatement
public java.sql.Statement createStatement()
throws java.sql.SQLException
prepareStatement
public java.sql.PreparedStatement prepareStatement(java.lang.String sql)
throws java.sql.SQLException
prepareCall
public java.sql.CallableStatement prepareCall(java.lang.String sql)
throws java.sql.SQLException
nativeSQL
public java.lang.String nativeSQL(java.lang.String sql)
throws java.sql.SQLException
setAutoCommit
public void setAutoCommit(boolean autoCommit)
throws java.sql.SQLException
getAutoCommit
public boolean getAutoCommit()
throws java.sql.SQLException
commit
public void commit()
throws java.sql.SQLException
rollback
public void rollback()
throws java.sql.SQLException
close
public void close()
throws java.sql.SQLException
isClosed
public boolean isClosed()
throws java.sql.SQLException
getMetaData
public java.sql.DatabaseMetaData getMetaData()
throws java.sql.SQLException
setReadOnly
public void setReadOnly(boolean readOnly)
throws java.sql.SQLException
isReadOnly
public boolean isReadOnly()
throws java.sql.SQLException
setCatalog
public void setCatalog(java.lang.String catalog)
throws java.sql.SQLException
getCatalog
public java.lang.String getCatalog()
throws java.sql.SQLException
setTransactionIsolation
public void setTransactionIsolation(int level)
throws java.sql.SQLException
getTransactionIsolation
public int getTransactionIsolation()
throws java.sql.SQLException
getWarnings
public java.sql.SQLWarning getWarnings()
throws java.sql.SQLException
clearWarnings
public void clearWarnings()
throws java.sql.SQLException
createStatement
public java.sql.Statement createStatement(int resultSetType,
int resultSetConcurrency)
throws java.sql.SQLException
prepareStatement
public java.sql.PreparedStatement prepareStatement(java.lang.String sql,
int resultSetType,
int resultSetConcurrency)
throws java.sql.SQLException
prepareCall
public java.sql.CallableStatement prepareCall(java.lang.String sql,
int resultSetType,
int resultSetConcurrency)
throws java.sql.SQLException
getTypeMap
public java.util.Map getTypeMap()
throws java.sql.SQLException
setTypeMap
public void setTypeMap(java.util.Map map)
throws java.sql.SQLException
archive
public void archive(int mode,
int aseq,
java.lang.String acstext)
throws java.sql.SQLException
- Specified by:
- archive in interface OracleConnection
getAutoClose
public boolean getAutoClose()
throws java.sql.SQLException
- Specified by:
- getAutoClose in interface OracleConnection
getCallWithKey
public java.sql.CallableStatement getCallWithKey(java.lang.String key)
throws java.sql.SQLException
- Specified by:
- getCallWithKey in interface OracleConnection
getDefaultExecuteBatch
public int getDefaultExecuteBatch()
- Specified by:
- getDefaultExecuteBatch in interface OracleConnection
getDefaultRowPrefetch
public int getDefaultRowPrefetch()
- Specified by:
- getDefaultRowPrefetch in interface OracleConnection
getDescriptor
public java.lang.Object getDescriptor(java.lang.String sql_name)
- Specified by:
- getDescriptor in interface OracleConnection
getIncludeSynonyms
public boolean getIncludeSynonyms()
- Specified by:
- getIncludeSynonyms in interface OracleConnection
getRestrictGetTables
public boolean getRestrictGetTables()
- Specified by:
- getRestrictGetTables in interface OracleConnection
getImplicitCachingEnabled
public boolean getImplicitCachingEnabled()
throws java.sql.SQLException
- Specified by:
- getImplicitCachingEnabled in interface OracleConnection
getExplicitCachingEnabled
public boolean getExplicitCachingEnabled()
throws java.sql.SQLException
- Specified by:
- getExplicitCachingEnabled in interface OracleConnection
getJavaObject
public java.lang.Object getJavaObject(java.lang.String sql_name)
throws java.sql.SQLException
- Specified by:
- getJavaObject in interface OracleConnection
getRemarksReporting
public boolean getRemarksReporting()
- Specified by:
- getRemarksReporting in interface OracleConnection
getSQLType
public java.lang.String getSQLType(java.lang.Object obj)
throws java.sql.SQLException
- Specified by:
- getSQLType in interface OracleConnection
getStmtCacheSize
public int getStmtCacheSize()
- Specified by:
- getStmtCacheSize in interface OracleConnection
getStatementCacheSize
public int getStatementCacheSize()
throws java.sql.SQLException
- Specified by:
- getStatementCacheSize in interface OracleConnection
getStatementWithKey
public java.sql.PreparedStatement getStatementWithKey(java.lang.String key)
throws java.sql.SQLException
- Specified by:
- getStatementWithKey in interface OracleConnection
getStructAttrCsId
public short getStructAttrCsId()
throws java.sql.SQLException
- Specified by:
- getStructAttrCsId in interface OracleConnection
getUserName
public java.lang.String getUserName()
throws java.sql.SQLException
- Specified by:
- getUserName in interface OracleConnection
getUsingXAFlag
public boolean getUsingXAFlag()
- Specified by:
- getUsingXAFlag in interface OracleConnection
getXAErrorFlag
public boolean getXAErrorFlag()
- Specified by:
- getXAErrorFlag in interface OracleConnection
oracleSetSavepoint
public OracleSavepoint oracleSetSavepoint()
throws java.sql.SQLException
- Specified by:
- oracleSetSavepoint in interface OracleConnection
oracleSetSavepoint
public OracleSavepoint oracleSetSavepoint(java.lang.String name)
throws java.sql.SQLException
- Specified by:
- oracleSetSavepoint in interface OracleConnection
oracleRollback
public void oracleRollback(OracleSavepoint savepoint)
throws java.sql.SQLException
- Specified by:
- oracleRollback in interface OracleConnection
oracleReleaseSavepoint
public void oracleReleaseSavepoint(OracleSavepoint savepoint)
throws java.sql.SQLException
- Specified by:
- oracleReleaseSavepoint in interface OracleConnection
pingDatabase
public int pingDatabase(int timeOut)
throws java.sql.SQLException
- Specified by:
- pingDatabase in interface OracleConnection
purgeExplicitCache
public void purgeExplicitCache()
throws java.sql.SQLException
- Specified by:
- purgeExplicitCache in interface OracleConnection
purgeImplicitCache
public void purgeImplicitCache()
throws java.sql.SQLException
- Specified by:
- purgeImplicitCache in interface OracleConnection
putDescriptor
public void putDescriptor(java.lang.String sql_name,
java.lang.Object desc)
throws java.sql.SQLException
- Specified by:
- putDescriptor in interface OracleConnection
registerSQLType
public void registerSQLType(java.lang.String sql_name,
java.lang.Class java_class)
throws java.sql.SQLException
- Specified by:
- registerSQLType in interface OracleConnection
registerSQLType
public void registerSQLType(java.lang.String sql_name,
java.lang.String java_class_name)
throws java.sql.SQLException
- Specified by:
- registerSQLType in interface OracleConnection
setAutoClose
public void setAutoClose(boolean autoClose)
throws java.sql.SQLException
- Specified by:
- setAutoClose in interface OracleConnection
setDefaultExecuteBatch
public void setDefaultExecuteBatch(int batch)
throws java.sql.SQLException
- Specified by:
- setDefaultExecuteBatch in interface OracleConnection
setDefaultRowPrefetch
public void setDefaultRowPrefetch(int value)
throws java.sql.SQLException
- Specified by:
- setDefaultRowPrefetch in interface OracleConnection
setExplicitCachingEnabled
public void setExplicitCachingEnabled(boolean cache)
throws java.sql.SQLException
- Specified by:
- setExplicitCachingEnabled in interface OracleConnection
setImplicitCachingEnabled
public void setImplicitCachingEnabled(boolean cache)
throws java.sql.SQLException
- Specified by:
- setImplicitCachingEnabled in interface OracleConnection
setIncludeSynonyms
public void setIncludeSynonyms(boolean synonyms)
- Specified by:
- setIncludeSynonyms in interface OracleConnection
setRemarksReporting
public void setRemarksReporting(boolean reportRemarks)
- Specified by:
- setRemarksReporting in interface OracleConnection
setRestrictGetTables
public void setRestrictGetTables(boolean restrict)
- Specified by:
- setRestrictGetTables in interface OracleConnection
setStmtCacheSize
public void setStmtCacheSize(int size)
throws java.sql.SQLException
- Specified by:
- setStmtCacheSize in interface OracleConnection
setStatementCacheSize
public void setStatementCacheSize(int size)
throws java.sql.SQLException
- Specified by:
- setStatementCacheSize in interface OracleConnection
setStmtCacheSize
public void setStmtCacheSize(int size,
boolean clearMetaData)
throws java.sql.SQLException
- Specified by:
- setStmtCacheSize in interface OracleConnection
setUsingXAFlag
public void setUsingXAFlag(boolean value)
- Specified by:
- setUsingXAFlag in interface OracleConnection
setXAErrorFlag
public void setXAErrorFlag(boolean value)
- Specified by:
- setXAErrorFlag in interface OracleConnection
shutdown
public void shutdown(int mode)
throws java.sql.SQLException
- Specified by:
- shutdown in interface OracleConnection
startup
public void startup(java.lang.String startup_str,
int mode)
throws java.sql.SQLException
- Specified by:
- startup in interface OracleConnection
prepareStatementWithKey
public java.sql.PreparedStatement prepareStatementWithKey(java.lang.String key)
throws java.sql.SQLException
- Specified by:
- prepareStatementWithKey in interface OracleConnection
prepareCallWithKey
public java.sql.CallableStatement prepareCallWithKey(java.lang.String key)
throws java.sql.SQLException
- Specified by:
- prepareCallWithKey in interface OracleConnection
setCreateStatementAsRefCursor
public void setCreateStatementAsRefCursor(boolean value)
- Specified by:
- setCreateStatementAsRefCursor in interface OracleConnection
getCreateStatementAsRefCursor
public boolean getCreateStatementAsRefCursor()
- Specified by:
- getCreateStatementAsRefCursor in interface OracleConnection
setSessionTimeZone
public void setSessionTimeZone(java.lang.String regionName)
throws java.sql.SQLException
- Specified by:
- setSessionTimeZone in interface OracleConnection
getSessionTimeZone
public java.lang.String getSessionTimeZone()
- Specified by:
- getSessionTimeZone in interface OracleConnection
assertComplete
public void assertComplete()
throws java.sql.SQLException
- Specified by:
- assertComplete in interface OracleConnection
getSynchronousMode
public boolean getSynchronousMode()
- Specified by:
- getSynchronousMode in interface OracleConnection
setSynchronousMode
public void setSynchronousMode(boolean isSynchronous)
- Specified by:
- setSynchronousMode in interface OracleConnection
registerApiDescription
public void registerApiDescription(java.lang.String apiName,
short major,
short minor,
java.lang.String className)
- Specified by:
- registerApiDescription in interface OracleConnection
openJoltConnection
public java.lang.Object openJoltConnection(java.lang.String apiName,
short major,
short minor)
- Specified by:
- openJoltConnection in interface OracleConnection
_getPC
public java.sql.Connection _getPC()
- Specified by:
- _getPC in interface OracleConnection
isLogicalConnection
public boolean isLogicalConnection()
- Specified by:
- isLogicalConnection in interface OracleConnection
registerTAFCallback
public void registerTAFCallback(OracleOCIFailover cbk,
java.lang.Object obj)
throws java.sql.SQLException
- Specified by:
- registerTAFCallback in interface OracleConnection
getProperties
public java.util.Properties getProperties()
- Specified by:
- getProperties in interface OracleConnection
setHoldability
public void setHoldability(int holdability)
throws java.sql.SQLException
getHoldability
public int getHoldability()
throws java.sql.SQLException
setSavepoint
public java.sql.Savepoint setSavepoint()
throws java.sql.SQLException
setSavepoint
public java.sql.Savepoint setSavepoint(java.lang.String name)
throws java.sql.SQLException
rollback
public void rollback(java.sql.Savepoint savepoint)
throws java.sql.SQLException
releaseSavepoint
public void releaseSavepoint(java.sql.Savepoint savepoint)
throws java.sql.SQLException
createStatement
public java.sql.Statement createStatement(int resultSetType,
int resultSetConcurrency,
int resultSetHoldability)
throws java.sql.SQLException
prepareStatement
public java.sql.PreparedStatement prepareStatement(java.lang.String sql,
int resultSetType,
int resultSetConcurrency,
int resultSetHoldability)
throws java.sql.SQLException
prepareCall
public java.sql.CallableStatement prepareCall(java.lang.String sql,
int resultSetType,
int resultSetConcurrency,
int resultSetHoldability)
throws java.sql.SQLException
prepareStatement
public java.sql.PreparedStatement prepareStatement(java.lang.String sql,
int autoGeneratedKeys)
throws java.sql.SQLException
prepareStatement
public java.sql.PreparedStatement prepareStatement(java.lang.String sql,
int[] columnIndexes)
throws java.sql.SQLException
prepareStatement
public java.sql.PreparedStatement prepareStatement(java.lang.String sql,
java.lang.String[] columnNames)
throws java.sql.SQLException