Visitable, RelationalOperatorpublic final class IsNullNode extends UnaryComparisonOperatorNode implements RelationalOperator
| Modifier and Type | Field | Description |
|---|---|---|
private boolean |
notNull |
If
true, this node represents a NOT NULL node rather than a
NULL node. |
private DataValueDescriptor |
nullValue |
AUTOINCREMENT_CREATE_MODIFY, AUTOINCREMENT_CYCLE, AUTOINCREMENT_INC_INDEX, AUTOINCREMENT_IS_AUTOINCREMENT_INDEX, AUTOINCREMENT_START_INDEXEQUALS_RELOP, GREATER_EQUALS_RELOP, GREATER_THAN_RELOP, IS_NOT_NULL_RELOP, IS_NULL_RELOP, LESS_EQUALS_RELOP, LESS_THAN_RELOP, NOT_EQUALS_RELOPK_BASE, K_XMLPARSE, K_XMLSERIALIZE, kind, methodName, operand, operator, receiverInterfaceType, resultInterfaceType, UnaryArgTypes, UnaryMethodNames, UnaryOperators, UnaryResultTypestransformed| Constructor | Description |
|---|---|
IsNullNode(ValueNode operand,
boolean notNull,
ContextManager cm) |
| Modifier and Type | Method | Description |
|---|---|---|
(package private) void |
bindParameter() |
Bind a ?
|
boolean |
compareWithKnownConstant(Optimizable optTable,
boolean considerParameters) |
Return whether this operator compares the given Optimizable with
a constant whose value is known at compile time.
|
boolean |
equalsComparisonWithConstantExpression(Optimizable optTable) |
Return whether this operator is an equality comparison of the given
optimizable with a constant expression.
|
void |
generateNegate(MethodBuilder mb,
Optimizable optTable) |
Generate an expression that evaluates to true if the result of the
comparison should be negated.
|
void |
generateOperator(MethodBuilder mb,
Optimizable optTable) |
Generate the comparison operator for this RelationalOperator.
|
DataValueDescriptor |
getCompareValue(Optimizable optTable) |
Return an Object representing the known value that this relational
operator is comparing to a column in the given Optimizable.
|
(package private) UnaryOperatorNode |
getNegation(ValueNode operand) |
Negate the comparison.
|
int |
getOperator() |
Return the operator (as an int) for this RelationalOperator.
|
(package private) java.lang.String |
getReceiverInterfaceName() |
null operators are defined on DataValueDescriptor.
|
int |
getStartOperator(Optimizable optTable) |
Get the start operator for a scan (at the store level) for this
RelationalOperator.
|
int |
getStopOperator(Optimizable optTable) |
Get the stop operator for a scan (at the store level) for this
RelationalOperator.
|
RelationalOperator |
getTransitiveSearchClause(ColumnReference otherCR) |
Return a relational operator which matches the current one
but with the passed in ColumnReference as the (left) operand.
|
(package private) boolean |
isNullNode() |
|
(package private) boolean |
isRelationalOperator() |
Returns true if this ValueNode is a relational operator.
|
(package private) boolean |
optimizableEqualityNode(Optimizable optTable,
int columnNumber,
boolean isNullOkay) |
Return true if the predicate represents an optimizable equality node.
|
double |
selectivity(Optimizable optTable) |
The default selectivity for value nodes is 50%.
|
private void |
updateOperatorDetails() |
|
boolean |
usefulStartKey(Optimizable optTable) |
Tell whether this relop is a useful start key for the given table.
|
boolean |
usefulStopKey(Optimizable optTable) |
Tell whether this relop is a useful stop key for the given table.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitpushSqlXmlUtilaccept, addTag, addUDTUsagePriv, addUDTUsagePriv, bindOffsetFetch, bindRowMultiSet, bindUserCatalogType, bindUserType, checkReliability, checkReliability, convertDefaultNode, copyTagsFrom, createTypeDependency, debugFlush, debugPrint, disablePrivilegeCollection, formatNodeString, 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, treePrint, treePrint, verifyClassExistgenerateAbsoluteColumnId, generateExpressionOperand, generateOrderedNulls, generateQualMethod, generateRelativeColumnId, getColumnOperand, getColumnOperand, getExpressionOperand, getOperand, getOrderableVariantType, isQualifier, orderedNulls, selfComparisonbindComparisonOperator, bindExpression, eliminateNots, generateAbsoluteColumnId, generateExpressionOperand, generateOrderedNulls, generateQualMethod, generateRelativeColumnId, getColumnOperand, getColumnOperand, getExpressionOperand, getOperand, getOrderableVariantType, isQualifier, orderedNulls, selfComparisonacceptChildren, addXmlOpMethodParams, bindOperand, categorize, constantExpression, generateExpression, getOperand, getOperatorString, getOrderableVariantType, getParameterOperand, isConstantExpression, isEquivalent, isSameNodeKind, preprocess, printSubNodes, remapColumnReferencesToExpressions, setMethodName, setOperator, toStringbindExpression, changeToCNF, checkIsBoolean, checkTopPredicatesForEqualsConditions, copyFields, evaluateConstantExpressions, genEqualsFalseTree, generate, genIsNullTree, genSQLJavaSQLTree, getClone, getColumnName, getConstantValueAsObject, getDataValueFactory, getSchemaName, getSourceResultColumn, getTableName, getTablesReferenced, getTransformed, getTypeCompiler, getTypeId, getTypeServices, isBinaryEqualsOperatorNode, isBooleanFalse, isBooleanTrue, isCloneable, isInListProbeNode, isParameterNode, putAndsOnTop, requiresTypeFromContext, setCollationInfo, setCollationInfo, setCollationUsingCompilationSchema, setCollationUsingCompilationSchema, setNullability, setTransformed, setType, setType, setType, updatableByCursor, verifyChangeToCNF, verifyEliminateNots, verifyPutAndsOnTopprivate DataValueDescriptor nullValue
private boolean notNull
true, this node represents a NOT NULL node rather than a
NULL node. Note that this state is mutable, cf getNegation(org.apache.derby.impl.sql.compile.ValueNode).IsNullNode(ValueNode operand, boolean notNull, ContextManager cm) throws StandardException
StandardExceptionprivate void updateOperatorDetails()
UnaryOperatorNode getNegation(ValueNode operand) throws StandardException
getNegation in class UnaryComparisonOperatorNodeoperand - The operand of the operatorStandardException - Thrown on errorvoid bindParameter()
throws StandardException
bindParameter in class UnaryOperatorNodeStandardException - Thrown on errorpublic boolean usefulStartKey(Optimizable optTable)
RelationalOperatorusefulStartKey in interface RelationalOperatoroptTable - The Optimizable table for which we want to know
whether this is a useful start key.RelationalOperator.usefulStartKey(org.apache.derby.iapi.sql.compile.Optimizable)public boolean usefulStopKey(Optimizable optTable)
RelationalOperatorusefulStopKey in interface RelationalOperatoroptTable - The Optimizable table for which we want to know
whether this is a useful stop key.RelationalOperator.usefulStopKey(org.apache.derby.iapi.sql.compile.Optimizable)public int getStartOperator(Optimizable optTable)
RelationalOperatorgetStartOperator in interface RelationalOperatorgetStartOperator in class UnaryComparisonOperatorNodeoptTable - The optimizable table we're doing the scan on.
This parameter is so we can tell which side of
the operator the table's column is on.RelationalOperator.getStartOperator(org.apache.derby.iapi.sql.compile.Optimizable)public int getStopOperator(Optimizable optTable)
RelationalOperatorgetStopOperator in interface RelationalOperatorgetStopOperator in class UnaryComparisonOperatorNodeoptTable - The optimizable table we're doing the scan on.
This parameter is so we can tell which side of
the operator the table's column is on.RelationalOperator.getStopOperator(org.apache.derby.iapi.sql.compile.Optimizable)public void generateOperator(MethodBuilder mb, Optimizable optTable)
RelationalOperatorgenerateOperator in interface RelationalOperatormb - The method the generated code is to go intooptTable - The optimizable table we're doing the scan on.RelationalOperator.generateOperator(org.apache.derby.iapi.services.compiler.MethodBuilder, org.apache.derby.iapi.sql.compile.Optimizable)public void generateNegate(MethodBuilder mb, Optimizable optTable)
RelationalOperatorgenerateNegate in interface RelationalOperatormb - The method the generated code is to go intooptTable - The Optimizable table the Qualifier will qualifyRelationalOperator.generateNegate(org.apache.derby.iapi.services.compiler.MethodBuilder, org.apache.derby.iapi.sql.compile.Optimizable)public int getOperator()
RelationalOperatorgetOperator in interface RelationalOperatorRelationalOperator.getOperator()public boolean compareWithKnownConstant(Optimizable optTable, boolean considerParameters)
RelationalOperatorcompareWithKnownConstant in interface RelationalOperatorRelationalOperator.compareWithKnownConstant(org.apache.derby.iapi.sql.compile.Optimizable, boolean)public DataValueDescriptor getCompareValue(Optimizable optTable) throws StandardException
RelationalOperatorgetCompareValue in interface RelationalOperatorStandardException - Thrown on errorRelationalOperator.getCompareValue(org.apache.derby.iapi.sql.compile.Optimizable)public boolean equalsComparisonWithConstantExpression(Optimizable optTable)
RelationalOperatorpublic RelationalOperator getTransitiveSearchClause(ColumnReference otherCR) throws StandardException
RelationalOperatorgetTransitiveSearchClause in interface RelationalOperatorotherCR - The ColumnReference for the new (left) operand.StandardException - thrown on errorRelationalOperator.getTransitiveSearchClause(org.apache.derby.impl.sql.compile.ColumnReference)java.lang.String getReceiverInterfaceName()
getReceiverInterfaceName in class UnaryOperatorNodepublic double selectivity(Optimizable optTable)
ValueNodeselectivity in class ValueNodeboolean isNullNode()
boolean isRelationalOperator()
ValueNodeisRelationalOperator in class ValueNodeValueNode.isRelationalOperator()boolean optimizableEqualityNode(Optimizable optTable, int columnNumber, boolean isNullOkay)
ValueNodeoptimizableEqualityNode in class ValueNodeoptTable - the table being optimized. Column reference must be from
this table.columnNumber - the column number. One of the operands of this
predicate must be the column number specified by optTable/columnNumberisNullOkay - if set to true we also consider IS NULL predicates;
otherwise consider only = predicates.ValueNode.optimizableEqualityNode(org.apache.derby.iapi.sql.compile.Optimizable, int, boolean)Apache Derby V10.14 Internals - Copyright © 2004,2018 The Apache Software Foundation. All Rights Reserved.