|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Object | +--com.ddtek.jxtr.JXTRStatement
The JXTRStatement class is used to determine the type of jXTransformer statement (jXTransformer query statement or write statement) and create the corresponding jXTransformer statement object (JXTRQuery or JXTRUpdate).
JXTRStatement only accepts statements using the jXTransformer statement grammar.
Using getStatementType(), you can determine whether the
specified statement text corresponds to a jXTransformer query or
jXTransformer write statement. Depending on the returned type,
use either getQueryStatement(java.sql.Connection),
getQueryStatement(java.sql.Connection,int) or
getUpdateStatement(java.sql.Connection) to create the
correct jXTransformer statement object.
| Field Summary | |
static int |
TYPE_QUERY
jXTransformer query statement type. |
static int |
TYPE_UPDATE
Write statement type (Insert, Update, or Delete). |
| Constructor Summary | |
JXTRStatement(java.lang.String jxtrStat)
Creates a new JXTRStatement. |
|
| Method Summary | |
JXTRQuery |
getQueryStatement(java.sql.Connection con)
Gets the query statement. |
JXTRQuery |
getQueryStatement(java.sql.Connection con,
int rewriteAlgorithm)
Creates a JXTRQuery object. |
int |
getStatementType()
Gets the statement type. |
JXTRUpdate |
getUpdateStatement(java.sql.Connection con)
Creates a JXTRUpdate object. |
boolean |
getXmlClausesDetected()
Returns true when the statement contains an XML construct, false when the statement does not contain an XML construct. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
public static final int TYPE_QUERY
public static final int TYPE_UPDATE
| Constructor Detail |
public JXTRStatement(java.lang.String jxtrStat)
throws JXTRException
JXTRStatement.
jxtrStat - A jXTransformer statement string.
java.lang.IllegalArgumentException - if
jxtrStat is null.
JXTRException - Refer to the JXTRException
class for more information about possible error conditions.| Method Detail |
public int getStatementType()
TYPE_QUERY or TYPE_UPDATE.
public JXTRQuery getQueryStatement(java.sql.Connection con)
throws JXTRException
getStatementType() returns TYPE_QUERY.
con - The JDBC connection.
JXTRQuery object.
java.lang.IllegalArgumentException - if con
is null.
JXTRException - Refer to the JXTRException
class for more information about possible error conditions.
public JXTRQuery getQueryStatement(java.sql.Connection con,
int rewriteAlgorithm)
throws JXTRException
getStatementType() returns TYPE_QUERY.
con - The JDBC connection.rewriteAlgorithm - One of the supported jXTransformer
query rewrite algorithms.
JXTRQuery object.
java.lang.IllegalArgumentException - if con
is null.
JXTRException - Refer to the JXTRException
class for more information about possible error conditions.
public JXTRUpdate getUpdateStatement(java.sql.Connection con)
throws JXTRException
getStatementType() returns TYPE_UPDATE.
con - The JDBC connection.
JXTRUpdate object.
java.lang.IllegalArgumentException - if con
is null.
JXTRException - Refer to the JXTRException
class for more information about possible error conditions.public boolean getXmlClausesDetected()
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||