Package org.jboss.jca.adapters.jdbc
Class CachedCallableStatement
java.lang.Object
org.jboss.jca.adapters.jdbc.JBossWrapper
org.jboss.jca.adapters.jdbc.CachedPreparedStatement
org.jboss.jca.adapters.jdbc.CachedCallableStatement
- All Implemented Interfaces:
Serializable,AutoCloseable,CallableStatement,PreparedStatement,Statement,Wrapper
- Direct Known Subclasses:
CachedCallableStatementJDK7,CachedCallableStatementJDK8
public abstract class CachedCallableStatement
extends CachedPreparedStatement
implements CallableStatement
A cache wrapper for java.sql.CallableStatement
- Version:
- $Revision: 76129 $
- Author:
- Andrew Belomutskiy, sstark@redhat.com
- See Also:
-
Field Summary
Fields inherited from class org.jboss.jca.adapters.jdbc.CachedPreparedStatement
logFields inherited from class org.jboss.jca.adapters.jdbc.JBossWrapper
bundleFields inherited from interface java.sql.Statement
CLOSE_ALL_RESULTS, CLOSE_CURRENT_RESULT, EXECUTE_FAILED, KEEP_CURRENT_RESULT, NO_GENERATED_KEYS, RETURN_GENERATED_KEYS, SUCCESS_NO_INFO -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidgetArray(int i) getBigDecimal(int parameterIndex) getBigDecimal(int parameterIndex, int scale) getBigDecimal(String parameterName) getBlob(int i) booleangetBoolean(int parameterIndex) booleangetBoolean(String parameterName) bytegetByte(int parameterIndex) bytebyte[]getBytes(int parameterIndex) byte[]getCharacterStream(int parameterIndex) getCharacterStream(String parameterName) getClob(int i) getDate(int parameterIndex) doublegetDouble(int parameterIndex) doublefloatgetFloat(int parameterIndex) floatintgetInt(int parameterIndex) intlonggetLong(int parameterIndex) longgetNCharacterStream(int parameterIndex) getNCharacterStream(String parameterName) getNClob(int parameterIndex) getNString(int parameterIndex) getNString(String parameterName) getObject(int parameterIndex) <T> T<T> TgetRef(int i) getRowId(int parameterIndex) shortgetShort(int parameterIndex) shortgetSQLXML(int parameterIndex) getString(int parameterIndex) getTime(int parameterIndex) getTimestamp(int parameterIndex) getTimestamp(int parameterIndex, Calendar cal) getTimestamp(String parameterName) getTimestamp(String parameterName, Calendar cal) getURL(int parameterIndex) protected CallableStatementGet the wrapped object - override in sub-classesbooleanisClosed()booleanbooleanvoidregisterOutParameter(int parameterIndex, int sqlType) voidregisterOutParameter(int parameterIndex, int sqlType, int scale) voidregisterOutParameter(int paramIndex, int sqlType, String typeName) voidregisterOutParameter(String parameterName, int sqlType) voidregisterOutParameter(String parameterName, int sqlType, int scale) voidregisterOutParameter(String parameterName, int sqlType, String typeName) voidsetAsciiStream(int parameterIndex, InputStream x) voidsetAsciiStream(int parameterIndex, InputStream x, long length) voidsetAsciiStream(String parameterName, InputStream x) voidsetAsciiStream(String parameterName, InputStream x, int length) voidsetAsciiStream(String parameterName, InputStream x, long length) voidsetBigDecimal(String parameterName, BigDecimal x) voidsetBinaryStream(int parameterIndex, InputStream x) voidsetBinaryStream(int parameterIndex, InputStream x, long length) voidsetBinaryStream(String parameterName, InputStream x) voidsetBinaryStream(String parameterName, InputStream x, int length) voidsetBinaryStream(String parameterName, InputStream x, long length) voidsetBlob(int parameterIndex, InputStream inputStream) voidsetBlob(int parameterIndex, InputStream inputStream, long length) voidsetBlob(String parameterName, InputStream inputStream) voidsetBlob(String parameterName, InputStream inputStream, long length) voidvoidsetBoolean(String parameterName, boolean x) voidvoidvoidsetCharacterStream(int parameterIndex, Reader reader) voidsetCharacterStream(int parameterIndex, Reader reader, long length) voidsetCharacterStream(String parameterName, Reader reader) voidsetCharacterStream(String parameterName, Reader reader, int length) voidsetCharacterStream(String parameterName, Reader reader, long length) voidvoidvoidvoidvoidvoidvoidvoidvoidvoidvoidvoidsetNCharacterStream(int parameterIndex, Reader value) voidsetNCharacterStream(int parameterIndex, Reader value, long length) voidsetNCharacterStream(String parameterName, Reader value) voidsetNCharacterStream(String parameterName, Reader value, long length) voidvoidvoidvoidvoidvoidvoidsetNString(int parameterIndex, String value) voidsetNString(String parameterName, String value) voidvoidvoidvoidvoidvoidsetPoolable(boolean poolable) voidvoidvoidvoidvoidvoidvoidvoidvoidsetTimestamp(String parameterName, Timestamp x) voidsetTimestamp(String parameterName, Timestamp x, Calendar cal) voidbooleanwasNull()Methods inherited from class org.jboss.jca.adapters.jdbc.CachedPreparedStatement
addBatch, addBatch, agedOut, cancel, clearBatch, clearParameters, clearWarnings, close, execute, execute, execute, execute, execute, executeBatch, executeQuery, executeQuery, executeUpdate, executeUpdate, executeUpdate, executeUpdate, executeUpdate, getConnection, getFetchDirection, getFetchSize, getGeneratedKeys, getMaxFieldSize, getMaxRows, getMetaData, getMoreResults, getMoreResults, getParameterMetaData, getQueryTimeout, getResultSet, getResultSetConcurrency, getResultSetHoldability, getResultSetType, getUnderlyingPreparedStatement, getUpdateCount, getWarnings, inUse, isInUse, setArray, setAsciiStream, setBigDecimal, setBinaryStream, setBlob, setBoolean, setByte, setBytes, setCharacterStream, setClob, setCursorName, setDate, setDate, setDouble, setEscapeProcessing, setFetchDirection, setFetchSize, setFloat, setInt, setLong, setMaxFieldSize, setMaxRows, setNull, setNull, setObject, setObject, setObject, setQueryTimeout, setRef, setShort, setString, setTime, setTime, setTimestamp, setTimestamp, setUnicodeStream, setURLMethods inherited from class org.jboss.jca.adapters.jdbc.JBossWrapper
isWrapperFor, unwrapMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface java.sql.CallableStatement
registerOutParameter, registerOutParameter, registerOutParameter, registerOutParameter, registerOutParameter, registerOutParameter, setObject, setObjectMethods inherited from interface java.sql.PreparedStatement
addBatch, clearParameters, execute, executeLargeUpdate, executeQuery, executeUpdate, getMetaData, getParameterMetaData, setArray, setAsciiStream, setBigDecimal, setBinaryStream, setBlob, setBoolean, setByte, setBytes, setCharacterStream, setClob, setDate, setDate, setDouble, setFloat, setInt, setLong, setNull, setNull, setObject, setObject, setObject, setObject, setObject, setRef, setShort, setString, setTime, setTime, setTimestamp, setTimestamp, setUnicodeStream, setURLMethods inherited from interface java.sql.Statement
addBatch, cancel, clearBatch, clearWarnings, close, enquoteIdentifier, enquoteLiteral, enquoteNCharLiteral, execute, execute, execute, execute, executeBatch, executeLargeBatch, executeLargeUpdate, executeLargeUpdate, executeLargeUpdate, executeLargeUpdate, executeQuery, executeUpdate, executeUpdate, executeUpdate, executeUpdate, getConnection, getFetchDirection, getFetchSize, getGeneratedKeys, getLargeMaxRows, getLargeUpdateCount, getMaxFieldSize, getMaxRows, getMoreResults, getMoreResults, getQueryTimeout, getResultSet, getResultSetConcurrency, getResultSetHoldability, getResultSetType, getUpdateCount, getWarnings, isSimpleIdentifier, setCursorName, setEscapeProcessing, setFetchDirection, setFetchSize, setLargeMaxRows, setMaxFieldSize, setMaxRows, setQueryTimeoutMethods inherited from interface java.sql.Wrapper
isWrapperFor, unwrap
-
Constructor Details
-
CachedCallableStatement
Constructor- Parameters:
cs- The statement- Throws:
SQLException- Thrown if an error occurs
-
-
Method Details
-
getUnderlyingCallableStatement
-
wasNull
- Specified by:
wasNullin interfaceCallableStatement- Throws:
SQLException
-
getByte
- Specified by:
getBytein interfaceCallableStatement- Throws:
SQLException
-
getDouble
- Specified by:
getDoublein interfaceCallableStatement- Throws:
SQLException
-
getFloat
- Specified by:
getFloatin interfaceCallableStatement- Throws:
SQLException
-
getInt
- Specified by:
getIntin interfaceCallableStatement- Throws:
SQLException
-
getLong
- Specified by:
getLongin interfaceCallableStatement- Throws:
SQLException
-
getShort
- Specified by:
getShortin interfaceCallableStatement- Throws:
SQLException
-
getBoolean
- Specified by:
getBooleanin interfaceCallableStatement- Throws:
SQLException
-
getBytes
- Specified by:
getBytesin interfaceCallableStatement- Throws:
SQLException
-
registerOutParameter
- Specified by:
registerOutParameterin interfaceCallableStatement- Throws:
SQLException
-
registerOutParameter
- Specified by:
registerOutParameterin interfaceCallableStatement- Throws:
SQLException
-
getObject
- Specified by:
getObjectin interfaceCallableStatement- Throws:
SQLException
-
getString
- Specified by:
getStringin interfaceCallableStatement- Throws:
SQLException
-
registerOutParameter
- Specified by:
registerOutParameterin interfaceCallableStatement- Throws:
SQLException
-
getByte
- Specified by:
getBytein interfaceCallableStatement- Throws:
SQLException
-
getDouble
- Specified by:
getDoublein interfaceCallableStatement- Throws:
SQLException
-
getFloat
- Specified by:
getFloatin interfaceCallableStatement- Throws:
SQLException
-
getInt
- Specified by:
getIntin interfaceCallableStatement- Throws:
SQLException
-
getLong
- Specified by:
getLongin interfaceCallableStatement- Throws:
SQLException
-
getShort
- Specified by:
getShortin interfaceCallableStatement- Throws:
SQLException
-
getBoolean
- Specified by:
getBooleanin interfaceCallableStatement- Throws:
SQLException
-
getBytes
- Specified by:
getBytesin interfaceCallableStatement- Throws:
SQLException
-
setByte
- Specified by:
setBytein interfaceCallableStatement- Throws:
SQLException
-
setDouble
- Specified by:
setDoublein interfaceCallableStatement- Throws:
SQLException
-
setFloat
- Specified by:
setFloatin interfaceCallableStatement- Throws:
SQLException
-
registerOutParameter
- Specified by:
registerOutParameterin interfaceCallableStatement- Throws:
SQLException
-
setInt
- Specified by:
setIntin interfaceCallableStatement- Throws:
SQLException
-
setNull
- Specified by:
setNullin interfaceCallableStatement- Throws:
SQLException
-
registerOutParameter
- Specified by:
registerOutParameterin interfaceCallableStatement- Throws:
SQLException
-
setLong
- Specified by:
setLongin interfaceCallableStatement- Throws:
SQLException
-
setShort
- Specified by:
setShortin interfaceCallableStatement- Throws:
SQLException
-
setBoolean
- Specified by:
setBooleanin interfaceCallableStatement- Throws:
SQLException
-
setBytes
- Specified by:
setBytesin interfaceCallableStatement- Throws:
SQLException
-
getBigDecimal
- Specified by:
getBigDecimalin interfaceCallableStatement- Throws:
SQLException
-
getBigDecimal
- Specified by:
getBigDecimalin interfaceCallableStatement- Throws:
SQLException
-
getURL
- Specified by:
getURLin interfaceCallableStatement- Throws:
SQLException
-
getArray
- Specified by:
getArrayin interfaceCallableStatement- Throws:
SQLException
-
getBlob
- Specified by:
getBlobin interfaceCallableStatement- Throws:
SQLException
-
getClob
- Specified by:
getClobin interfaceCallableStatement- Throws:
SQLException
-
getDate
- Specified by:
getDatein interfaceCallableStatement- Throws:
SQLException
-
getRef
- Specified by:
getRefin interfaceCallableStatement- Throws:
SQLException
-
getTime
- Specified by:
getTimein interfaceCallableStatement- Throws:
SQLException
-
getTimestamp
- Specified by:
getTimestampin interfaceCallableStatement- Throws:
SQLException
-
setAsciiStream
- Specified by:
setAsciiStreamin interfaceCallableStatement- Throws:
SQLException
-
setBinaryStream
- Specified by:
setBinaryStreamin interfaceCallableStatement- Throws:
SQLException
-
setCharacterStream
- Specified by:
setCharacterStreamin interfaceCallableStatement- Throws:
SQLException
-
getObject
- Specified by:
getObjectin interfaceCallableStatement- Throws:
SQLException
-
setObject
- Specified by:
setObjectin interfaceCallableStatement- Throws:
SQLException
-
setObject
- Specified by:
setObjectin interfaceCallableStatement- Throws:
SQLException
-
setObject
public void setObject(String parameterName, Object x, int targetSqlType, int scale) throws SQLException - Specified by:
setObjectin interfaceCallableStatement- Throws:
SQLException
-
getObject
- Specified by:
getObjectin interfaceCallableStatement- Throws:
SQLException
-
getString
- Specified by:
getStringin interfaceCallableStatement- Throws:
SQLException
-
registerOutParameter
public void registerOutParameter(String parameterName, int sqlType, String typeName) throws SQLException - Specified by:
registerOutParameterin interfaceCallableStatement- Throws:
SQLException
-
setNull
- Specified by:
setNullin interfaceCallableStatement- Throws:
SQLException
-
setString
- Specified by:
setStringin interfaceCallableStatement- Throws:
SQLException
-
getBigDecimal
- Specified by:
getBigDecimalin interfaceCallableStatement- Throws:
SQLException
-
setBigDecimal
- Specified by:
setBigDecimalin interfaceCallableStatement- Throws:
SQLException
-
getURL
- Specified by:
getURLin interfaceCallableStatement- Throws:
SQLException
-
setURL
- Specified by:
setURLin interfaceCallableStatement- Throws:
SQLException
-
getArray
- Specified by:
getArrayin interfaceCallableStatement- Throws:
SQLException
-
getBlob
- Specified by:
getBlobin interfaceCallableStatement- Throws:
SQLException
-
getClob
- Specified by:
getClobin interfaceCallableStatement- Throws:
SQLException
-
getDate
- Specified by:
getDatein interfaceCallableStatement- Throws:
SQLException
-
setDate
- Specified by:
setDatein interfaceCallableStatement- Throws:
SQLException
-
getDate
- Specified by:
getDatein interfaceCallableStatement- Throws:
SQLException
-
getRef
- Specified by:
getRefin interfaceCallableStatement- Throws:
SQLException
-
getTime
- Specified by:
getTimein interfaceCallableStatement- Throws:
SQLException
-
setTime
- Specified by:
setTimein interfaceCallableStatement- Throws:
SQLException
-
getTime
- Specified by:
getTimein interfaceCallableStatement- Throws:
SQLException
-
getTimestamp
- Specified by:
getTimestampin interfaceCallableStatement- Throws:
SQLException
-
setTimestamp
- Specified by:
setTimestampin interfaceCallableStatement- Throws:
SQLException
-
getTimestamp
- Specified by:
getTimestampin interfaceCallableStatement- Throws:
SQLException
-
getObject
- Specified by:
getObjectin interfaceCallableStatement- Throws:
SQLException
-
getDate
- Specified by:
getDatein interfaceCallableStatement- Throws:
SQLException
-
getTime
- Specified by:
getTimein interfaceCallableStatement- Throws:
SQLException
-
getTimestamp
- Specified by:
getTimestampin interfaceCallableStatement- Throws:
SQLException
-
setDate
- Specified by:
setDatein interfaceCallableStatement- Throws:
SQLException
-
setTime
- Specified by:
setTimein interfaceCallableStatement- Throws:
SQLException
-
setTimestamp
- Specified by:
setTimestampin interfaceCallableStatement- Throws:
SQLException
-
setAsciiStream
- Specified by:
setAsciiStreamin interfacePreparedStatement- Overrides:
setAsciiStreamin classCachedPreparedStatement- Throws:
SQLException
-
setAsciiStream
- Specified by:
setAsciiStreamin interfacePreparedStatement- Overrides:
setAsciiStreamin classCachedPreparedStatement- Throws:
SQLException
-
setBinaryStream
- Specified by:
setBinaryStreamin interfacePreparedStatement- Overrides:
setBinaryStreamin classCachedPreparedStatement- Throws:
SQLException
-
setBinaryStream
- Specified by:
setBinaryStreamin interfacePreparedStatement- Overrides:
setBinaryStreamin classCachedPreparedStatement- Throws:
SQLException
-
setBlob
- Specified by:
setBlobin interfacePreparedStatement- Overrides:
setBlobin classCachedPreparedStatement- Throws:
SQLException
-
setBlob
- Specified by:
setBlobin interfacePreparedStatement- Overrides:
setBlobin classCachedPreparedStatement- Throws:
SQLException
-
setCharacterStream
- Specified by:
setCharacterStreamin interfacePreparedStatement- Overrides:
setCharacterStreamin classCachedPreparedStatement- Throws:
SQLException
-
setCharacterStream
- Specified by:
setCharacterStreamin interfacePreparedStatement- Overrides:
setCharacterStreamin classCachedPreparedStatement- Throws:
SQLException
-
setClob
- Specified by:
setClobin interfacePreparedStatement- Overrides:
setClobin classCachedPreparedStatement- Throws:
SQLException
-
setClob
- Specified by:
setClobin interfacePreparedStatement- Overrides:
setClobin classCachedPreparedStatement- Throws:
SQLException
-
setNCharacterStream
- Specified by:
setNCharacterStreamin interfacePreparedStatement- Overrides:
setNCharacterStreamin classCachedPreparedStatement- Throws:
SQLException
-
setNCharacterStream
- Specified by:
setNCharacterStreamin interfacePreparedStatement- Overrides:
setNCharacterStreamin classCachedPreparedStatement- Throws:
SQLException
-
setNClob
- Specified by:
setNClobin interfacePreparedStatement- Overrides:
setNClobin classCachedPreparedStatement- Throws:
SQLException
-
setNClob
- Specified by:
setNClobin interfacePreparedStatement- Overrides:
setNClobin classCachedPreparedStatement- Throws:
SQLException
-
setNClob
- Specified by:
setNClobin interfacePreparedStatement- Overrides:
setNClobin classCachedPreparedStatement- Throws:
SQLException
-
setNString
- Specified by:
setNStringin interfacePreparedStatement- Overrides:
setNStringin classCachedPreparedStatement- Throws:
SQLException
-
setRowId
- Specified by:
setRowIdin interfacePreparedStatement- Overrides:
setRowIdin classCachedPreparedStatement- Throws:
SQLException
-
setSQLXML
- Specified by:
setSQLXMLin interfacePreparedStatement- Overrides:
setSQLXMLin classCachedPreparedStatement- Throws:
SQLException
-
isClosed
- Specified by:
isClosedin interfaceStatement- Overrides:
isClosedin classCachedPreparedStatement- Throws:
SQLException
-
isPoolable
- Specified by:
isPoolablein interfaceStatement- Overrides:
isPoolablein classCachedPreparedStatement- Throws:
SQLException
-
setPoolable
- Specified by:
setPoolablein interfaceStatement- Overrides:
setPoolablein classCachedPreparedStatement- Throws:
SQLException
-
getCharacterStream
- Specified by:
getCharacterStreamin interfaceCallableStatement- Throws:
SQLException
-
getCharacterStream
- Specified by:
getCharacterStreamin interfaceCallableStatement- Throws:
SQLException
-
getNCharacterStream
- Specified by:
getNCharacterStreamin interfaceCallableStatement- Throws:
SQLException
-
getNCharacterStream
- Specified by:
getNCharacterStreamin interfaceCallableStatement- Throws:
SQLException
-
getNClob
- Specified by:
getNClobin interfaceCallableStatement- Throws:
SQLException
-
getNClob
- Specified by:
getNClobin interfaceCallableStatement- Throws:
SQLException
-
getNString
- Specified by:
getNStringin interfaceCallableStatement- Throws:
SQLException
-
getNString
- Specified by:
getNStringin interfaceCallableStatement- Throws:
SQLException
-
getRowId
- Specified by:
getRowIdin interfaceCallableStatement- Throws:
SQLException
-
getRowId
- Specified by:
getRowIdin interfaceCallableStatement- Throws:
SQLException
-
getSQLXML
- Specified by:
getSQLXMLin interfaceCallableStatement- Throws:
SQLException
-
getSQLXML
- Specified by:
getSQLXMLin interfaceCallableStatement- Throws:
SQLException
-
setAsciiStream
- Specified by:
setAsciiStreamin interfaceCallableStatement- Throws:
SQLException
-
setAsciiStream
- Specified by:
setAsciiStreamin interfaceCallableStatement- Throws:
SQLException
-
setBinaryStream
- Specified by:
setBinaryStreamin interfaceCallableStatement- Throws:
SQLException
-
setBinaryStream
- Specified by:
setBinaryStreamin interfaceCallableStatement- Throws:
SQLException
-
setBlob
- Specified by:
setBlobin interfaceCallableStatement- Throws:
SQLException
-
setBlob
- Specified by:
setBlobin interfaceCallableStatement- Throws:
SQLException
-
setBlob
- Specified by:
setBlobin interfaceCallableStatement- Throws:
SQLException
-
setCharacterStream
public void setCharacterStream(String parameterName, Reader reader, long length) throws SQLException - Specified by:
setCharacterStreamin interfaceCallableStatement- Throws:
SQLException
-
setCharacterStream
- Specified by:
setCharacterStreamin interfaceCallableStatement- Throws:
SQLException
-
setClob
- Specified by:
setClobin interfaceCallableStatement- Throws:
SQLException
-
setClob
- Specified by:
setClobin interfaceCallableStatement- Throws:
SQLException
-
setClob
- Specified by:
setClobin interfaceCallableStatement- Throws:
SQLException
-
setNCharacterStream
public void setNCharacterStream(String parameterName, Reader value, long length) throws SQLException - Specified by:
setNCharacterStreamin interfaceCallableStatement- Throws:
SQLException
-
setNCharacterStream
- Specified by:
setNCharacterStreamin interfaceCallableStatement- Throws:
SQLException
-
setNClob
- Specified by:
setNClobin interfaceCallableStatement- Throws:
SQLException
-
setNClob
- Specified by:
setNClobin interfaceCallableStatement- Throws:
SQLException
-
setNClob
- Specified by:
setNClobin interfaceCallableStatement- Throws:
SQLException
-
setNString
- Specified by:
setNStringin interfaceCallableStatement- Throws:
SQLException
-
setRowId
- Specified by:
setRowIdin interfaceCallableStatement- Throws:
SQLException
-
setSQLXML
- Specified by:
setSQLXMLin interfaceCallableStatement- Throws:
SQLException
-
closeOnCompletion
- Specified by:
closeOnCompletionin interfaceStatement- Overrides:
closeOnCompletionin classCachedPreparedStatement- Throws:
SQLException
-
isCloseOnCompletion
- Specified by:
isCloseOnCompletionin interfaceStatement- Overrides:
isCloseOnCompletionin classCachedPreparedStatement- Throws:
SQLException
-
getObject
- Specified by:
getObjectin interfaceCallableStatement- Throws:
SQLException
-
getObject
- Specified by:
getObjectin interfaceCallableStatement- Throws:
SQLException
-
getWrappedObject
Get the wrapped object - override in sub-classes- Overrides:
getWrappedObjectin classCachedPreparedStatement- Returns:
- The object
- Throws:
SQLException- Thrown if an error occurs
-