|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectorg.objectweb.cjdbc.common.sql.AbstractRequest
org.objectweb.cjdbc.common.sql.AbstractWriteRequest
An AbstractWriteRequest defines the skeleton of read requests
that are sent from the driver to the controller.
| Field Summary | |
protected boolean |
blocking
true if this request might block. |
protected java.util.ArrayList |
columns
ArrayList of TableColumn involved in this
write query. |
protected java.lang.String |
pkValue
Primary key value |
protected java.lang.String |
tableName
Name of the table involved in this write query. |
| Fields inherited from class org.objectweb.cjdbc.common.sql.AbstractRequest |
cacheable, escapeProcessing, id, isAutoCommit, isParsed, isReadOnly, login, maxRows, sqlQuery, sqlSkeleton, timeout, transactionId |
| Constructor Summary | |
AbstractWriteRequest(java.lang.String sqlQuery,
boolean escapeProcessing,
int timeout,
java.lang.String lineSeparator)
Creates a new AbstractWriteRequest object |
|
| Method Summary | |
protected void |
cloneTableNameAndColumns(AbstractWriteRequest abstractWriteRequest)
Clones table name and columns from an already parsed request. |
java.util.ArrayList |
getColumns()
Returns an ArrayList of TableColumn objects
representing the columns affected by this statement. |
java.lang.String |
getPk()
|
java.lang.String |
getTableName()
Returns the name of the table affected by this statement. |
abstract boolean |
isAlter()
Returns true if this request in a ALTER
statement. |
abstract boolean |
isCreate()
Returns true if this request in a CREATE
statement. |
abstract boolean |
isDelete()
Returns true if this request in a DELETE
statement. |
abstract boolean |
isDrop()
Returns true if this request in a DROP
statement. |
abstract boolean |
isInsert()
Returns true if this request in an INSERT
statement. |
boolean |
isReadRequest()
Returns true if this request is a read request (
SELECT requests for example perform a read). |
boolean |
isUnknownRequest()
Returns true if the resulting operation on this request is
unknown (some non-standard command or stored procedure for example). |
abstract boolean |
isUpdate()
Returns true if this request in an UPDATE
statement. |
boolean |
isWriteRequest()
Returns true if this request is a write request (
INSERT or UPDATE for example perform writes). |
boolean |
mightBlock()
Tests if this request might block. |
void |
setBlocking(boolean blocking)
Sets if this request might block. |
| Methods inherited from class org.objectweb.cjdbc.common.sql.AbstractRequest |
cloneParsing, debug, equals, getCacheAbility, getEscapeProcessing, getFetchSize, getId, getLineSeparator, getLogin, getMaxRows, getSQL, getSQLShortForm, getSqlSkeleton, getTimeout, getTransactionId, isAutoCommit, isDriverProcessed, isParsed, isReadOnly, parse, setCacheAbility, setDriverProcessed, setFetchSize, setId, setIsAutoCommit, setIsReadOnly, setLineSeparator, setLogin, setMaxRows, setSQL, setSqlSkeleton, setTimeout, setTransactionId, trimCarriageReturn |
| Methods inherited from class java.lang.Object |
clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
protected transient java.lang.String tableName
protected transient java.util.ArrayList columns
ArrayList of TableColumn involved in this
write query.
protected transient boolean blocking
true if this request might block.
protected transient java.lang.String pkValue
| Constructor Detail |
public AbstractWriteRequest(java.lang.String sqlQuery,
boolean escapeProcessing,
int timeout,
java.lang.String lineSeparator)
AbstractWriteRequest object
sqlQuery - the SQL queryescapeProcessing - should the driver to escape processing before
sending to the database ?timeout - an int valuelineSeparator - the line separator used in the query| Method Detail |
public boolean isReadRequest()
AbstractRequesttrue if this request is a read request (
SELECT requests for example perform a read).
isReadRequest in class AbstractRequestfalseAbstractRequest.isReadRequest()public boolean isWriteRequest()
AbstractRequesttrue if this request is a write request (
INSERT or UPDATE for example perform writes).
isWriteRequest in class AbstractRequesttrueAbstractRequest.isWriteRequest()public boolean isUnknownRequest()
AbstractRequesttrue if the resulting operation on this request is
unknown (some non-standard command or stored procedure for example).
isUnknownRequest in class AbstractRequestfalseAbstractRequest.isUnknownRequest()public abstract boolean isInsert()
true if this request in an INSERT
statement.
boolean valuepublic abstract boolean isUpdate()
true if this request in an UPDATE
statement.
boolean valuepublic abstract boolean isDelete()
true if this request in a DELETE
statement.
boolean valuepublic abstract boolean isAlter()
true if this request in a ALTER
statement.
boolean valuepublic abstract boolean isCreate()
true if this request in a CREATE
statement.
boolean valuepublic abstract boolean isDrop()
true if this request in a DROP
statement.
boolean valuepublic java.lang.String getTableName()
String valuepublic java.util.ArrayList getColumns()
ArrayList of TableColumn objects
representing the columns affected by this statement.
ArrayList valueprotected void cloneTableNameAndColumns(AbstractWriteRequest abstractWriteRequest)
abstractWriteRequest - the already parsed requestpublic boolean mightBlock()
true if this request might blockpublic void setBlocking(boolean blocking)
blocking - a boolean valuepublic java.lang.String getPk()
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||