public class P6PreparedStatement extends P6Statement implements PreparedStatement
Modifier and Type | Field and Description |
---|---|
protected boolean[] |
isString |
static int |
P6_GROW_MAX |
static int |
P6_MAX_FIELDS |
protected String |
preparedQuery |
protected PreparedStatement |
prepStmtPassthru |
protected Object[] |
values |
connection, passthru, statementQuery
CLOSE_ALL_RESULTS, CLOSE_CURRENT_RESULT, EXECUTE_FAILED, KEEP_CURRENT_RESULT, NO_GENERATED_KEYS, RETURN_GENERATED_KEYS, SUCCESS_NO_INFO
Constructor and Description |
---|
P6PreparedStatement(P6Factory factory,
PreparedStatement statement,
P6Connection conn,
String query) |
Modifier and Type | Method and Description |
---|---|
void |
addBatch() |
void |
clearParameters() |
boolean |
execute() |
ResultSet |
executeQuery() |
int |
executeUpdate() |
Statement |
getJDBC()
Returns the underlying JDBC object (in this case, a
java.sql.PreparedStatement).
|
ResultSetMetaData |
getMetaData() |
ParameterMetaData |
getParameterMetaData() |
String |
getQueryFromPreparedStatement() |
ResultSet |
getResultSet() |
int |
getValuesLength() |
protected void |
growValues(int newMax) |
protected void |
initValues() |
void |
setArray(int p0,
Array p1) |
void |
setAsciiStream(int arg0,
InputStream arg1) |
void |
setAsciiStream(int p0,
InputStream p1,
int p2) |
void |
setAsciiStream(int arg0,
InputStream arg1,
long arg2) |
void |
setBigDecimal(int p0,
BigDecimal p1) |
void |
setBinaryStream(int arg0,
InputStream arg1) |
void |
setBinaryStream(int p0,
InputStream p1,
int p2) |
void |
setBinaryStream(int arg0,
InputStream arg1,
long arg2) |
void |
setBlob(int p0,
Blob p1) |
void |
setBlob(int arg0,
InputStream arg1) |
void |
setBlob(int arg0,
InputStream arg1,
long arg2) |
void |
setBoolean(int p0,
boolean p1) |
void |
setByte(int p0,
byte p1) |
void |
setBytes(int p0,
byte[] p1) |
void |
setCharacterStream(int arg0,
Reader arg1) |
void |
setCharacterStream(int p0,
Reader p1,
int p2) |
void |
setCharacterStream(int arg0,
Reader arg1,
long arg2) |
void |
setClob(int p0,
Clob p1) |
void |
setClob(int arg0,
Reader arg1) |
void |
setClob(int arg0,
Reader arg1,
long arg2) |
void |
setDate(int p0,
Date p1) |
void |
setDate(int p0,
Date p1,
Calendar p2) |
void |
setDouble(int p0,
double p1) |
void |
setFloat(int p0,
float p1) |
void |
setInt(int p0,
int p1) |
void |
setLong(int p0,
long p1) |
void |
setNCharacterStream(int arg0,
Reader arg1) |
void |
setNCharacterStream(int arg0,
Reader arg1,
long arg2) |
void |
setNClob(int arg0,
NClob arg1) |
void |
setNClob(int arg0,
Reader arg1) |
void |
setNClob(int arg0,
Reader arg1,
long arg2) |
void |
setNString(int arg0,
String arg1) |
void |
setNull(int p0,
int p1) |
void |
setNull(int p0,
int p1,
String p2) |
void |
setObject(int p0,
Object p1) |
void |
setObject(int p0,
Object p1,
int p2) |
void |
setObject(int p0,
Object p1,
int p2,
int p3) |
protected void |
setObjectAsInt(int i,
Object o) |
protected void |
setObjectAsString(int i,
Object o) |
void |
setRef(int p0,
Ref p1) |
void |
setRowId(int arg0,
RowId arg1) |
void |
setShort(int p0,
short p1) |
void |
setSQLXML(int arg0,
SQLXML arg1) |
void |
setString(int p0,
String p1) |
void |
setTime(int p0,
Time p1) |
void |
setTime(int p0,
Time p1,
Calendar p2) |
void |
setTimestamp(int p0,
Timestamp p1) |
void |
setTimestamp(int p0,
Timestamp p1,
Calendar p2) |
void |
setUnicodeStream(int p0,
InputStream p1,
int p2) |
void |
setURL(int p0,
URL p1) |
addBatch, cancel, clearBatch, clearWarnings, close, closeOnCompletion, execute, execute, execute, execute, executeBatch, executeQuery, executeUpdate, executeUpdate, executeUpdate, executeUpdate, getConnection, getFetchDirection, getFetchSize, getGeneratedKeys, getMaxFieldSize, getMaxRows, getMoreResults, getMoreResults, getQueryTimeout, getResultSetConcurrency, getResultSetHoldability, getResultSetType, getUpdateCount, getWarnings, isClosed, isCloseOnCompletion, isPoolable, isWrapperFor, setCursorName, setEscapeProcessing, setFetchDirection, setFetchSize, setMaxFieldSize, setMaxRows, setPoolable, setQueryTimeout, unwrap
getP6Factory, setP6Factory
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
executeLargeUpdate, setObject, setObject
addBatch, cancel, clearBatch, clearWarnings, close, closeOnCompletion, 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, getResultSetConcurrency, getResultSetHoldability, getResultSetType, getUpdateCount, getWarnings, isClosed, isCloseOnCompletion, isPoolable, setCursorName, setEscapeProcessing, setFetchDirection, setFetchSize, setLargeMaxRows, setMaxFieldSize, setMaxRows, setPoolable, setQueryTimeout
isWrapperFor, unwrap
public static final int P6_MAX_FIELDS
public static int P6_GROW_MAX
protected PreparedStatement prepStmtPassthru
protected String preparedQuery
protected Object[] values
protected boolean[] isString
public P6PreparedStatement(P6Factory factory, PreparedStatement statement, P6Connection conn, String query)
protected void initValues()
public void addBatch() throws SQLException
addBatch
in interface PreparedStatement
SQLException
public void clearParameters() throws SQLException
clearParameters
in interface PreparedStatement
SQLException
public boolean execute() throws SQLException
execute
in interface PreparedStatement
SQLException
public ResultSet executeQuery() throws SQLException
executeQuery
in interface PreparedStatement
SQLException
public int executeUpdate() throws SQLException
executeUpdate
in interface PreparedStatement
SQLException
public ResultSetMetaData getMetaData() throws SQLException
getMetaData
in interface PreparedStatement
SQLException
public void setArray(int p0, Array p1) throws SQLException
setArray
in interface PreparedStatement
SQLException
public void setAsciiStream(int p0, InputStream p1, int p2) throws SQLException
setAsciiStream
in interface PreparedStatement
SQLException
public void setBigDecimal(int p0, BigDecimal p1) throws SQLException
setBigDecimal
in interface PreparedStatement
SQLException
public void setBinaryStream(int p0, InputStream p1, int p2) throws SQLException
setBinaryStream
in interface PreparedStatement
SQLException
public void setBlob(int p0, Blob p1) throws SQLException
setBlob
in interface PreparedStatement
SQLException
public void setBoolean(int p0, boolean p1) throws SQLException
setBoolean
in interface PreparedStatement
SQLException
public void setByte(int p0, byte p1) throws SQLException
setByte
in interface PreparedStatement
SQLException
public void setBytes(int p0, byte[] p1) throws SQLException
setBytes
in interface PreparedStatement
SQLException
public void setCharacterStream(int p0, Reader p1, int p2) throws SQLException
setCharacterStream
in interface PreparedStatement
SQLException
public void setClob(int p0, Clob p1) throws SQLException
setClob
in interface PreparedStatement
SQLException
public void setDate(int p0, Date p1) throws SQLException
setDate
in interface PreparedStatement
SQLException
public void setDate(int p0, Date p1, Calendar p2) throws SQLException
setDate
in interface PreparedStatement
SQLException
public void setDouble(int p0, double p1) throws SQLException
setDouble
in interface PreparedStatement
SQLException
public void setFloat(int p0, float p1) throws SQLException
setFloat
in interface PreparedStatement
SQLException
public void setInt(int p0, int p1) throws SQLException
setInt
in interface PreparedStatement
SQLException
public void setLong(int p0, long p1) throws SQLException
setLong
in interface PreparedStatement
SQLException
public void setNull(int p0, int p1, String p2) throws SQLException
setNull
in interface PreparedStatement
SQLException
public void setNull(int p0, int p1) throws SQLException
setNull
in interface PreparedStatement
SQLException
public void setObject(int p0, Object p1, int p2, int p3) throws SQLException
setObject
in interface PreparedStatement
SQLException
public void setObject(int p0, Object p1, int p2) throws SQLException
setObject
in interface PreparedStatement
SQLException
public void setObject(int p0, Object p1) throws SQLException
setObject
in interface PreparedStatement
SQLException
public void setRef(int p0, Ref p1) throws SQLException
setRef
in interface PreparedStatement
SQLException
public void setShort(int p0, short p1) throws SQLException
setShort
in interface PreparedStatement
SQLException
public void setString(int p0, String p1) throws SQLException
setString
in interface PreparedStatement
SQLException
public void setTime(int p0, Time p1, Calendar p2) throws SQLException
setTime
in interface PreparedStatement
SQLException
public void setTime(int p0, Time p1) throws SQLException
setTime
in interface PreparedStatement
SQLException
public void setTimestamp(int p0, Timestamp p1, Calendar p2) throws SQLException
setTimestamp
in interface PreparedStatement
SQLException
public void setTimestamp(int p0, Timestamp p1) throws SQLException
setTimestamp
in interface PreparedStatement
SQLException
public void setUnicodeStream(int p0, InputStream p1, int p2) throws SQLException
setUnicodeStream
in interface PreparedStatement
SQLException
public ResultSet getResultSet() throws SQLException
getResultSet
in interface Statement
getResultSet
in class P6Statement
SQLException
public final String getQueryFromPreparedStatement()
protected void growValues(int newMax)
protected void setObjectAsString(int i, Object o)
protected void setObjectAsInt(int i, Object o)
public void setURL(int p0, URL p1) throws SQLException
setURL
in interface PreparedStatement
SQLException
public ParameterMetaData getParameterMetaData() throws SQLException
getParameterMetaData
in interface PreparedStatement
SQLException
public Statement getJDBC()
The returned object is a java.sql.Statement due to inheritance reasons, so you'll need to cast appropriately.
getJDBC
in class P6Statement
public int getValuesLength()
public void setAsciiStream(int arg0, InputStream arg1) throws SQLException
setAsciiStream
in interface PreparedStatement
SQLException
public void setAsciiStream(int arg0, InputStream arg1, long arg2) throws SQLException
setAsciiStream
in interface PreparedStatement
SQLException
public void setBinaryStream(int arg0, InputStream arg1) throws SQLException
setBinaryStream
in interface PreparedStatement
SQLException
public void setBinaryStream(int arg0, InputStream arg1, long arg2) throws SQLException
setBinaryStream
in interface PreparedStatement
SQLException
public void setBlob(int arg0, InputStream arg1) throws SQLException
setBlob
in interface PreparedStatement
SQLException
public void setBlob(int arg0, InputStream arg1, long arg2) throws SQLException
setBlob
in interface PreparedStatement
SQLException
public void setCharacterStream(int arg0, Reader arg1) throws SQLException
setCharacterStream
in interface PreparedStatement
SQLException
public void setCharacterStream(int arg0, Reader arg1, long arg2) throws SQLException
setCharacterStream
in interface PreparedStatement
SQLException
public void setClob(int arg0, Reader arg1) throws SQLException
setClob
in interface PreparedStatement
SQLException
public void setClob(int arg0, Reader arg1, long arg2) throws SQLException
setClob
in interface PreparedStatement
SQLException
public void setNCharacterStream(int arg0, Reader arg1) throws SQLException
setNCharacterStream
in interface PreparedStatement
SQLException
public void setNCharacterStream(int arg0, Reader arg1, long arg2) throws SQLException
setNCharacterStream
in interface PreparedStatement
SQLException
public void setNClob(int arg0, NClob arg1) throws SQLException
setNClob
in interface PreparedStatement
SQLException
public void setNClob(int arg0, Reader arg1) throws SQLException
setNClob
in interface PreparedStatement
SQLException
public void setNClob(int arg0, Reader arg1, long arg2) throws SQLException
setNClob
in interface PreparedStatement
SQLException
public void setNString(int arg0, String arg1) throws SQLException
setNString
in interface PreparedStatement
SQLException
public void setRowId(int arg0, RowId arg1) throws SQLException
setRowId
in interface PreparedStatement
SQLException
public void setSQLXML(int arg0, SQLXML arg1) throws SQLException
setSQLXML
in interface PreparedStatement
SQLException