|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.objectweb.cjdbc.common.sql.AbstractRequest org.objectweb.cjdbc.common.sql.AbstractWriteRequest org.objectweb.cjdbc.common.sql.DropRequest
An DropRequest
is an SQL request with the following syntax:
DROP TABLE table-name
Field Summary | |
private static long |
serialVersionUID
|
Fields inherited from class org.objectweb.cjdbc.common.sql.AbstractWriteRequest |
blocking, columns, pkValue, tableName |
Fields inherited from class org.objectweb.cjdbc.common.sql.AbstractRequest |
cacheable, cursorName, escapeProcessing, fetchSize, id, isAutoCommit, isParsed, isReadOnly, login, maxRows, requestType, sqlQuery, sqlSkeleton, timeoutInSeconds, transactionId, transactionIsolation |
Constructor Summary | |
DropRequest(CJDBCInputStream in)
|
|
DropRequest(java.lang.String sqlQuery,
boolean escapeProcessing,
int timeout,
java.lang.String lineSeparator)
Creates a new DropRequest instance. |
|
DropRequest(java.lang.String sqlQuery,
boolean escapeProcessing,
int timeout,
java.lang.String lineSeparator,
DatabaseSchema schema,
int granularity,
boolean isCaseSensitive)
Creates a new DropRequest instance. |
Method Summary | |
void |
cloneParsing(AbstractRequest request)
Clones the parsing of a request. |
void |
debug()
Displays some debugging information about this request. |
boolean |
needsMacroProcessing()
Returns true if this request requires macro (RAND(), NOW(),
...) processing. |
void |
parse(DatabaseSchema schema,
int granularity,
boolean isCaseSensitive)
Parses the SQL request and extract the selected columns and tables given the DatabaseSchema of the database targeted by this request.
|
boolean |
returnsResultSet()
Does this request returns a ResultSet? |
Methods inherited from class org.objectweb.cjdbc.common.sql.AbstractWriteRequest |
cloneTableNameAndColumns, getColumns, getPk, getTableName, mightBlock, setBlocking |
Methods inherited from class org.objectweb.cjdbc.common.sql.AbstractRequest |
equals, getCacheAbility, getCursorName, getEscapeProcessing, getFetchSize, getId, getLineSeparator, getLogin, getMaxRows, getSQL, getSQLShortForm, getSqlSkeleton, getTimeout, getTransactionId, getTransactionIsolation, isAlter, isAutoCommit, isCreate, isDDL, isDelete, isDML, isDriverProcessed, isDrop, isInsert, isParsed, isReadOnly, isSelect, isUpdate, receiveResultSetParams, sendResultSetParams, sendToStream, setCacheAbility, setCursorName, setDriverProcessed, setFetchSize, setId, setIsAutoCommit, setIsReadOnly, setLogin, setMaxRows, setSQL, setSqlSkeleton, setTimeout, setTransactionId, setTransactionIsolation, trimCarriageReturnAndTabs |
Methods inherited from class java.lang.Object |
clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
private static final long serialVersionUID
Constructor Detail |
public DropRequest(java.lang.String sqlQuery, boolean escapeProcessing, int timeout, java.lang.String lineSeparator, DatabaseSchema schema, int granularity, boolean isCaseSensitive) throws java.sql.SQLException
DropRequest
instance. The caller must give an
SQL request, without any leading or trailing spaces and beginning with
'drop table ' (it will not be checked).
If the syntax is incorrect an exception is thrown.
sqlQuery
- a String
valueescapeProcessing
- should the driver to escape processing before
sending to the database ?timeout
- an int
valuelineSeparator
- the line separator used in the queryschema
- a DatabaseSchema
valuegranularity
- parsing granularity as defined in
ParsingGranularities
isCaseSensitive
- true if parsing is case sensitive
java.sql.SQLException
- if an error occurspublic DropRequest(java.lang.String sqlQuery, boolean escapeProcessing, int timeout, java.lang.String lineSeparator)
DropRequest
instance. The caller must give an
SQL request, without any leading or trailing spaces and beginning with
'create table ' (it will not be checked).
The request is not parsed but it can be done later by a call to
parse(DatabaseSchema, int, boolean)
.
sqlQuery
- the SQL requestescapeProcessing
- should the driver to escape processing before
sending to the database ?timeout
- an int
valuelineSeparator
- the line separator used in the queryparse(org.objectweb.cjdbc.common.sql.schema.DatabaseSchema, int, boolean)
public DropRequest(CJDBCInputStream in) throws java.io.IOException
AbstractWriteRequest
Method Detail |
public void parse(DatabaseSchema schema, int granularity, boolean isCaseSensitive) throws java.sql.SQLException
AbstractRequest
DatabaseSchema
of the database targeted by this request.
An exception is thrown when the parsing fails. Warning, this method does not check the validity of the request. In particular, invalid request could be parsed without throwing an exception. However, valid SQL request should never throw an exception.
parse
in class AbstractRequest
schema
- a DatabaseSchema
valuegranularity
- parsing granularity as defined in
ParsingGranularities
isCaseSensitive
- true if parsing must be case sensitive
java.sql.SQLException
- if the parsing failsAbstractRequest.parse(org.objectweb.cjdbc.common.sql.schema.DatabaseSchema,
int, boolean)
public void cloneParsing(AbstractRequest request)
AbstractRequest
cloneParsing
in class AbstractRequest
request
- the parsed request to cloneAbstractRequest.cloneParsing(AbstractRequest)
public boolean needsMacroProcessing()
AbstractRequest
true
if this request requires macro (RAND(), NOW(),
...) processing.
needsMacroProcessing
in class AbstractRequest
true
if macro processing is requiredAbstractRequest.needsMacroProcessing()
public boolean returnsResultSet()
AbstractRequest
returnsResultSet
in class AbstractRequest
AbstractRequest.returnsResultSet()
public void debug()
debug
in class AbstractRequest
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |