se.unlogic.standardutils.dao.querys
Class PreparedStatementQuery
java.lang.Object
se.unlogic.standardutils.dao.querys.PreparedStatementQuery
- Direct Known Subclasses:
- BooleanQuery, PopulatedQuery, UpdateQuery
public abstract class PreparedStatementQuery
- extends java.lang.Object
Constructor Summary |
PreparedStatementQuery(java.sql.Connection connection,
boolean closeConnectionOnExit,
java.lang.String query)
|
PreparedStatementQuery(javax.sql.DataSource dataSource,
boolean closeConnectionOnExit,
java.lang.String query)
|
Method Summary |
void |
abort()
|
static void |
autoCloseQuery(PreparedStatementQuery query)
|
protected java.sql.PreparedStatement |
getPreparedStatement(java.lang.String query)
|
boolean |
isCloseConnectionOnExit()
|
boolean |
isClosed()
|
void |
setArray(int arg0,
java.sql.Array arg1)
|
void |
setAsciiStream(int arg0,
java.io.InputStream arg1,
int arg2)
|
void |
setBigDecimal(int arg0,
java.math.BigDecimal arg1)
|
void |
setBinaryStream(int arg0,
java.io.InputStream arg1,
int arg2)
|
void |
setBlob(int arg0,
java.sql.Blob arg1)
|
void |
setBoolean(int arg0,
boolean arg1)
|
void |
setByte(int arg0,
byte arg1)
|
void |
setBytes(int arg0,
byte[] arg1)
|
void |
setCharacterStream(int arg0,
java.io.Reader arg1,
int arg2)
|
void |
setClob(int arg0,
java.sql.Clob arg1)
|
void |
setCursorName(java.lang.String arg0)
|
void |
setDate(int arg0,
java.sql.Date arg1)
|
void |
setDate(int arg0,
java.sql.Date arg1,
java.util.Calendar arg2)
|
void |
setDouble(int arg0,
double arg1)
|
void |
setEscapeProcessing(boolean arg0)
|
void |
setFetchDirection(int arg0)
|
void |
setFetchSize(int arg0)
|
void |
setFloat(int arg0,
float arg1)
|
void |
setInt(int arg0,
int arg1)
|
void |
setLong(int arg0,
long arg1)
|
void |
setMaxFieldSize(int arg0)
|
void |
setMaxRows(int arg0)
|
void |
setNull(int arg0,
int arg1)
|
void |
setNull(int arg0,
int arg1,
java.lang.String arg2)
|
void |
setObject(int arg0,
java.lang.Object arg1)
|
void |
setObject(int arg0,
java.lang.Object arg1,
int arg2)
|
void |
setObject(int arg0,
java.lang.Object arg1,
int arg2,
int arg3)
|
void |
setQueryTimeout(int arg0)
|
void |
setRef(int arg0,
java.sql.Ref arg1)
|
void |
setShort(int arg0,
short arg1)
|
void |
setString(int arg0,
java.lang.String arg1)
|
void |
setTime(int arg0,
java.sql.Time arg1)
|
void |
setTime(int arg0,
java.sql.Time arg1,
java.util.Calendar arg2)
|
void |
setTimestamp(int arg0,
java.sql.Timestamp arg1)
|
void |
setTimestamp(int arg0,
java.sql.Timestamp arg1,
java.util.Calendar arg2)
|
void |
setURL(int arg0,
java.net.URL arg1)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
connection
protected java.sql.Connection connection
closeConnectionOnExit
protected boolean closeConnectionOnExit
pstmt
protected java.sql.PreparedStatement pstmt
closed
protected boolean closed
PreparedStatementQuery
public PreparedStatementQuery(java.sql.Connection connection,
boolean closeConnectionOnExit,
java.lang.String query)
throws java.sql.SQLException
- Throws:
java.sql.SQLException
PreparedStatementQuery
public PreparedStatementQuery(javax.sql.DataSource dataSource,
boolean closeConnectionOnExit,
java.lang.String query)
throws java.sql.SQLException
- Throws:
java.sql.SQLException
getPreparedStatement
protected java.sql.PreparedStatement getPreparedStatement(java.lang.String query)
throws java.sql.SQLException
- Throws:
java.sql.SQLException
setArray
public void setArray(int arg0,
java.sql.Array arg1)
throws java.sql.SQLException
- Throws:
java.sql.SQLException
setAsciiStream
public void setAsciiStream(int arg0,
java.io.InputStream arg1,
int arg2)
throws java.sql.SQLException
- Throws:
java.sql.SQLException
setBigDecimal
public void setBigDecimal(int arg0,
java.math.BigDecimal arg1)
throws java.sql.SQLException
- Throws:
java.sql.SQLException
setBinaryStream
public void setBinaryStream(int arg0,
java.io.InputStream arg1,
int arg2)
throws java.sql.SQLException
- Throws:
java.sql.SQLException
setBlob
public void setBlob(int arg0,
java.sql.Blob arg1)
throws java.sql.SQLException
- Throws:
java.sql.SQLException
setBoolean
public void setBoolean(int arg0,
boolean arg1)
throws java.sql.SQLException
- Throws:
java.sql.SQLException
setByte
public void setByte(int arg0,
byte arg1)
throws java.sql.SQLException
- Throws:
java.sql.SQLException
setBytes
public void setBytes(int arg0,
byte[] arg1)
throws java.sql.SQLException
- Throws:
java.sql.SQLException
setCharacterStream
public void setCharacterStream(int arg0,
java.io.Reader arg1,
int arg2)
throws java.sql.SQLException
- Throws:
java.sql.SQLException
setClob
public void setClob(int arg0,
java.sql.Clob arg1)
throws java.sql.SQLException
- Throws:
java.sql.SQLException
setCursorName
public void setCursorName(java.lang.String arg0)
throws java.sql.SQLException
- Throws:
java.sql.SQLException
setDate
public void setDate(int arg0,
java.sql.Date arg1,
java.util.Calendar arg2)
throws java.sql.SQLException
- Throws:
java.sql.SQLException
setDate
public void setDate(int arg0,
java.sql.Date arg1)
throws java.sql.SQLException
- Throws:
java.sql.SQLException
setDouble
public void setDouble(int arg0,
double arg1)
throws java.sql.SQLException
- Throws:
java.sql.SQLException
setEscapeProcessing
public void setEscapeProcessing(boolean arg0)
throws java.sql.SQLException
- Throws:
java.sql.SQLException
setFetchDirection
public void setFetchDirection(int arg0)
throws java.sql.SQLException
- Throws:
java.sql.SQLException
setFetchSize
public void setFetchSize(int arg0)
throws java.sql.SQLException
- Throws:
java.sql.SQLException
setFloat
public void setFloat(int arg0,
float arg1)
throws java.sql.SQLException
- Throws:
java.sql.SQLException
setInt
public void setInt(int arg0,
int arg1)
throws java.sql.SQLException
- Throws:
java.sql.SQLException
setLong
public void setLong(int arg0,
long arg1)
throws java.sql.SQLException
- Throws:
java.sql.SQLException
setMaxFieldSize
public void setMaxFieldSize(int arg0)
throws java.sql.SQLException
- Throws:
java.sql.SQLException
setMaxRows
public void setMaxRows(int arg0)
throws java.sql.SQLException
- Throws:
java.sql.SQLException
setNull
public void setNull(int arg0,
int arg1,
java.lang.String arg2)
throws java.sql.SQLException
- Throws:
java.sql.SQLException
setNull
public void setNull(int arg0,
int arg1)
throws java.sql.SQLException
- Throws:
java.sql.SQLException
setObject
public void setObject(int arg0,
java.lang.Object arg1,
int arg2,
int arg3)
throws java.sql.SQLException
- Throws:
java.sql.SQLException
setObject
public void setObject(int arg0,
java.lang.Object arg1,
int arg2)
throws java.sql.SQLException
- Throws:
java.sql.SQLException
setObject
public void setObject(int arg0,
java.lang.Object arg1)
throws java.sql.SQLException
- Throws:
java.sql.SQLException
setQueryTimeout
public void setQueryTimeout(int arg0)
throws java.sql.SQLException
- Throws:
java.sql.SQLException
setRef
public void setRef(int arg0,
java.sql.Ref arg1)
throws java.sql.SQLException
- Throws:
java.sql.SQLException
setShort
public void setShort(int arg0,
short arg1)
throws java.sql.SQLException
- Throws:
java.sql.SQLException
setString
public void setString(int arg0,
java.lang.String arg1)
throws java.sql.SQLException
- Throws:
java.sql.SQLException
setTime
public void setTime(int arg0,
java.sql.Time arg1,
java.util.Calendar arg2)
throws java.sql.SQLException
- Throws:
java.sql.SQLException
setTime
public void setTime(int arg0,
java.sql.Time arg1)
throws java.sql.SQLException
- Throws:
java.sql.SQLException
setTimestamp
public void setTimestamp(int arg0,
java.sql.Timestamp arg1,
java.util.Calendar arg2)
throws java.sql.SQLException
- Throws:
java.sql.SQLException
setTimestamp
public void setTimestamp(int arg0,
java.sql.Timestamp arg1)
throws java.sql.SQLException
- Throws:
java.sql.SQLException
setURL
public void setURL(int arg0,
java.net.URL arg1)
throws java.sql.SQLException
- Throws:
java.sql.SQLException
isCloseConnectionOnExit
public boolean isCloseConnectionOnExit()
abort
public void abort()
autoCloseQuery
public static void autoCloseQuery(PreparedStatementQuery query)
isClosed
public boolean isClosed()
Copyright © 2011. All Rights Reserved.