|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.apache.derby.impl.sql.compile.QueryTreeNode
org.apache.derby.impl.sql.compile.StatementNode
public abstract class StatementNode
A StatementNode represents a single statement in the language. It is the top node for any statement.
StatementNode controls the class generation for query tree nodes.
| Field Summary | |
|---|---|
(package private) static TableDescriptor[] |
EMPTY_TD_LIST
Cached empty list object. |
(package private) static int |
NEED_CURSOR_ACTIVATION
|
(package private) static int |
NEED_DDL_ACTIVATION
create the outer shell class builder for the class we will be generating, generate the expression to stuff in it, and turn it into a class. |
(package private) static int |
NEED_NOTHING_ACTIVATION
|
(package private) static int |
NEED_PARAM_ACTIVATION
|
(package private) static int |
NEED_ROW_ACTIVATION
|
| Fields inherited from class org.apache.derby.impl.sql.compile.QueryTreeNode |
|---|
AUTOINCREMENT_CREATE_MODIFY, AUTOINCREMENT_INC_INDEX, AUTOINCREMENT_IS_AUTOINCREMENT_INDEX, AUTOINCREMENT_START_INDEX, isPrivilegeCollectionRequired |
| Constructor Summary | |
|---|---|
StatementNode()
|
|
| Method Summary | |
|---|---|
(package private) abstract int |
activationKind()
|
void |
bindStatement()
Perform the binding operation statement. |
java.lang.String |
executeSchemaName()
Returns name of schema in EXECUTE STATEMENT command. |
java.lang.String |
executeStatementName()
Returns the name of statement in EXECUTE STATEMENT command. |
GeneratedClass |
generate(ByteArray byteCode)
Do code generation for this statement. |
java.lang.String |
getSPSName()
Get the name of the SPS that is used to execute this statement. |
boolean |
isAtomic()
By default, assume StatementNodes are atomic. |
protected TableDescriptor |
lockTableForCompilation(TableDescriptor td)
|
ResultDescription |
makeResultDescription()
Only DML statements have result descriptions - for all others return null. |
boolean |
needsSavepoint()
Returns whether or not this Statement requires a set/clear savepoint around its execution. |
void |
optimizeStatement()
Generates an optimized statement from a bound StatementNode. |
abstract java.lang.String |
statementToString()
|
java.lang.String |
toString()
Convert this object to a String. |
TableDescriptor[] |
updateIndexStatisticsFor()
Returns a list of base tables for which the index statistics of the associated indexes should be updated. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
static final TableDescriptor[] EMPTY_TD_LIST
static final int NEED_DDL_ACTIVATION
static final int NEED_CURSOR_ACTIVATION
static final int NEED_PARAM_ACTIVATION
static final int NEED_ROW_ACTIVATION
static final int NEED_NOTHING_ACTIVATION
| Constructor Detail |
|---|
public StatementNode()
| Method Detail |
|---|
public boolean isAtomic()
throws StandardException
isAtomic in class QueryTreeNodeStandardException - Thrown on errorpublic boolean needsSavepoint()
ONLY CALLABLE AFTER GENERATION
This implementation returns true, sub-classes can override the method to not require a savepoint.
public java.lang.String getSPSName()
public java.lang.String executeStatementName()
public java.lang.String executeSchemaName()
public ResultDescription makeResultDescription()
public java.lang.String toString()
toString in class QueryTreeNodepublic abstract java.lang.String statementToString()
public void bindStatement()
throws StandardException
StandardException - Thrown on error
public void optimizeStatement()
throws StandardException
StandardException - Thrown on errorabstract int activationKind()
protected TableDescriptor lockTableForCompilation(TableDescriptor td)
throws StandardException
StandardException
public GeneratedClass generate(ByteArray byteCode)
throws StandardException
byteCode - the generated byte code for this statement.
if non-null, then the byte code is saved
here.
StandardException - Thrown on error
public TableDescriptor[] updateIndexStatisticsFor()
throws StandardException
This default implementation always returns an empty list.
StandardException - if accessing the index descriptors of a base
table fails
|
Built on Wed 2013-06-12 15:21:56+0000, from revision ??? | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||