class ValueNodeList extends QueryTreeNodeVector<ValueNode>
AUTOINCREMENT_CREATE_MODIFY, AUTOINCREMENT_CYCLE, AUTOINCREMENT_INC_INDEX, AUTOINCREMENT_IS_AUTOINCREMENT_INDEX, AUTOINCREMENT_START_INDEX
eltClass
Constructor | Description |
---|---|
ValueNodeList(ContextManager cm) |
Modifier and Type | Method | Description |
---|---|---|
(package private) void |
addValueNode(ValueNode valueNode) |
Add a ValueNode to the list.
|
(package private) boolean |
allSamePrecendence(int precedence) |
Return whether or not all of the entries in the list have the same
type precendence as the specified value.
|
(package private) void |
bindExpression(FromList fromList,
SubqueryList subqueryList,
java.util.List<AggregateNode> aggregates) |
Bind this expression.
|
(package private) boolean |
categorize(JBitSet referencedTabs,
boolean simplePredsOnly) |
Categorize this predicate.
|
(package private) void |
comparable(ValueNode leftOperand) |
Determine whether or not the leftOperand is comparable() with all of
the elements in the list.
|
(package private) void |
compatible(ValueNode leftOperand) |
Make sure that passed ValueNode's type is compatible with the non-parameter elements in the ValueNodeList.
|
(package private) boolean |
constantExpression(PredicateList whereClause) |
|
(package private) boolean |
containsAllConstantNodes() |
Does this list contain all ConstantNodes?
|
(package private) boolean |
containsAllParameterNodes() |
Does this list contain all ParameterNodes?
|
(package private) boolean |
containsOnlyConstantAndParamNodes() |
Does this list *only* contain constant and/or parameter nodes?
|
(package private) boolean |
containsParameterNode() |
Does this list contain a ParameterNode?
|
(package private) void |
eliminateNots(boolean underNotNode) |
Eliminate NotNodes in all the nodes in this list.
|
(package private) void |
genSQLJavaSQLTrees() |
Generate a SQL->Java->SQL conversion tree any node in the list
which is not a system built-in type.
|
(package private) DataTypeDescriptor |
getDominantTypeServices() |
Get the dominant DataTypeServices from the elements in the list.
|
protected int |
getOrderableVariantType() |
Return the variant type for the underlying expression.
|
(package private) DataTypeDescriptor |
getTypeServices() |
Get the first non-null DataTypeServices from the elements in the list.
|
(package private) boolean |
isConstantExpression() |
Return whether or not this expression tree represents a constant expression.
|
(package private) boolean |
isEquivalent(ValueNodeList other) |
Check if all the elements in this list are equivalent to the elements
in another list.
|
(package private) boolean |
isNullable() |
Determine whether or not any of the elements in the list are nullable.
|
(package private) void |
preprocess(int numTables,
FromList outerFromList,
SubqueryList outerSubqueryList,
PredicateList outerPredicateList) |
Preprocess a ValueNodeList.
|
(package private) ValueNodeList |
remapColumnReferencesToExpressions() |
Remap all ColumnReferences in this tree to be clones of the
underlying expression.
|
(package private) void |
setParameterDescriptor(DataTypeDescriptor descriptor) |
Set the descriptor for every ParameterNode in the list.
|
(package private) void |
sortInAscendingOrder(DataValueDescriptor judgeODV) |
Sort the entries in the list in ascending order.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
accept, addTag, addUDTUsagePriv, addUDTUsagePriv, bindOffsetFetch, bindRowMultiSet, bindUserCatalogType, bindUserType, checkReliability, checkReliability, convertDefaultNode, copyTagsFrom, createTypeDependency, debugFlush, debugPrint, disablePrivilegeCollection, formatNodeString, generate, generateAuthorizeCheck, getBeginOffset, getClassFactory, getCompilerContext, getContext, getContextManager, getDataDictionary, getDependencyManager, getEndOffset, getExecutionFactory, getGenericConstantActionFactory, getIntProperty, getLanguageConnectionContext, getLongProperty, getNullNode, getOffsetOrderedNodes, getOptimizerFactory, getOptimizerTracer, getParameterTypes, getSchemaDescriptor, getSchemaDescriptor, getStatementType, getTableDescriptor, getTypeCompiler, getUDTDesc, isAtomic, isPrivilegeCollectionRequired, isSessionSchema, isSessionSchema, makeConstantAction, makeTableName, makeTableName, nodeHeader, optimizerTracingIsOn, orReliability, parseSearchCondition, parseStatement, printLabel, referencesSessionSchema, resolveTableToSynonym, setBeginOffset, setEndOffset, setRefActionInfo, stackPrint, taggedWith, toString, treePrint, treePrint, verifyClassExist
acceptChildren, addElement, destructiveAppend, elementAt, indexOf, insertElementAt, iterator, nondestructiveAppend, printSubNodes, removeAllElements, removeElement, removeElementAt, setElementAt, size
ValueNodeList(ContextManager cm)
void addValueNode(ValueNode valueNode) throws StandardException
valueNode
- A ValueNode to add to the listStandardException
- Thrown on errorvoid bindExpression(FromList fromList, SubqueryList subqueryList, java.util.List<AggregateNode> aggregates) throws StandardException
fromList
- The FROM list for the query this
expression is in, for binding columns.subqueryList
- The subquery list being built as we find SubqueryNodesaggregates
- The aggregate list being built as we find AggregateNodesStandardException
- Thrown on errorvoid genSQLJavaSQLTrees() throws StandardException
StandardException
- Thrown on errorDataTypeDescriptor getDominantTypeServices() throws StandardException
StandardException
- Thrown on errorWith that algorithm, if one DTD has collation derivation of NONE and the
other DTD has collation derivation of IMPLICIT, then the return DTD from
DTD.getDominantType will have collation derivation of IMPLICIT. That is
not the correct algorithm for aggregate operators. SQL standards says
that if EVERY type has implicit derivation AND is of the same type, then
the collation of the resultant will be of that type with derivation
IMPLICIT. To provide this behavior for aggregate operator, we basically
ignore the collation type and derivation picked by
DataTypeDescriptor.getDominantType. Instead we let
getDominantTypeServices use the simple algorithm listed at the top of
this method's comments to determine the collation type and derivation
for this ValueNodeList object.
DataTypeDescriptor getTypeServices() throws StandardException
StandardException
- Thrown on errorboolean allSamePrecendence(int precedence)
precedence
- The specified precedence.void compatible(ValueNode leftOperand) throws StandardException
leftOperand
- Check for compatibility against this parameter's typeStandardException
void comparable(ValueNode leftOperand) throws StandardException
leftOperand
- The left side of the expressionStandardException
- Thrown on errorboolean isNullable() throws StandardException
StandardException
boolean containsParameterNode()
boolean containsAllParameterNodes()
boolean containsAllConstantNodes()
boolean containsOnlyConstantAndParamNodes()
void sortInAscendingOrder(DataValueDescriptor judgeODV) throws StandardException
judgeODV
- In case of type not exactly matching, the judging type.StandardException
- Thrown on errorvoid eliminateNots(boolean underNotNode) throws StandardException
underNotNode
- whether or not we are under a NotNodeStandardException
ValueNode.eliminateNots(boolean)
void setParameterDescriptor(DataTypeDescriptor descriptor) throws StandardException
descriptor
- The DataTypeServices to set for the parametersStandardException
- Thrown on errorvoid preprocess(int numTables, FromList outerFromList, SubqueryList outerSubqueryList, PredicateList outerPredicateList) throws StandardException
numTables
- Number of tables in the DML StatementouterFromList
- FromList from outer query blockouterSubqueryList
- SubqueryList from outer query blockouterPredicateList
- PredicateList from outer query blockStandardException
- Thrown on errorValueNodeList remapColumnReferencesToExpressions() throws StandardException
StandardException
- Thrown on errorboolean isEquivalent(ValueNodeList other) throws StandardException
other
- the other listtrue
if the two lists contain equivalent elements, or
false
otherwiseStandardException
- thrown on errorValueNode.isEquivalent(ValueNode)
boolean isConstantExpression()
boolean constantExpression(PredicateList whereClause)
boolean categorize(JBitSet referencedTabs, boolean simplePredsOnly) throws StandardException
referencedTabs
- JBitSet with bit map of referenced FromTablessimplePredsOnly
- Whether or not to consider method
calls, field references and conditional nodes
when building bit mapStandardException
- Thrown on errorprotected int getOrderableVariantType() throws StandardException
StandardException
- thrown on errorApache Derby V10.14 Internals - Copyright © 2004,2018 The Apache Software Foundation. All Rights Reserved.