Class OMathExpression
java.lang.Object
com.orientechnologies.orient.core.sql.parser.SimpleNode
com.orientechnologies.orient.core.sql.parser.OMathExpression
- All Implemented Interfaces:
Node
- Direct Known Subclasses:
OBaseExpression,OFirstLevelExpression,OParenthesisExpression
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected List<OMathExpression>protected List<OMathExpression.Operator>Fields inherited from class com.orientechnologies.orient.core.sql.parser.SimpleNode
children, firstToken, id, lastToken, PARAMETER_PLACEHOLDER, parent, parser, value -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidaddChildExpression(OMathExpression expression) voidaddOperator(OMathExpression.Operator operator) booleanallowsIndexedFunctionExecutionOnTarget(OFromClause target, OCommandContext context, OBinaryCompareOperator operator, Object right) tests if current expression is an indexed function AND that function can be used on this targetvoidapplyRemove(OResultInternal result, OCommandContext ctx) booleancanExecuteIndexedFunctionWithoutIndex(OFromClause target, OCommandContext context, OBinaryCompareOperator operator, Object right) tests if current expression is an indexed function AND that function can also be executed without using the indexcopy()voiddeserialize(OResult fromResult) static OMathExpressiondeserializeFromResult(OResult fromResult) booleanlongestimateIndexedFunction(OFromClause target, OCommandContext context, OBinaryCompareOperator operator, Object right) execute(OResult iCurrentRecord, OCommandContext ctx) executeIndexedFunction(OFromClause target, OCommandContext context, OBinaryCompareOperator operator, Object right) booleanexecuteIndexedFunctionAfterIndexSearch(OFromClause target, OCommandContext context, OBinaryCompareOperator operator, Object right) tests if current expression is an indexed function AND the function has also to be executed after the index search.voidextractSubQueries(OIdentifier letAlias, SubQueryCollector collector) voidextractSubQueries(SubQueryCollector collector) getCollate(OResult currentRecord, OCommandContext ctx) getPath()inthashCode()booleanbooleanbooleanbooleanisCount()booleanisDefinedFor(OElement currentRecord) booleanisDefinedFor(OResult currentRecord) booleanbooleanisExpand()booleanbooleanbooleanisIndexChain(OCommandContext ctx, OClass clazz) booleanbooleanbooleanisSelf()booleanneedsAliases(Set<String> aliases) booleanvoidsetChildExpressions(List<OMathExpression> childExpressions) splitForAggregation(AggregateProjectionSplit aggregateProj, OCommandContext ctx) protected booleanvoidtoGenericStatement(StringBuilder builder) voidtoString(Map<Object, Object> params, StringBuilder builder) Methods inherited from class com.orientechnologies.orient.core.sql.parser.SimpleNode
dump, getValue, jjtAddChild, jjtClose, jjtGetChild, jjtGetFirstToken, jjtGetLastToken, jjtGetNumChildren, jjtGetParent, jjtGetValue, jjtOpen, jjtSetFirstToken, jjtSetLastToken, jjtSetParent, jjtSetValue, toGenericStatement, toString, toString
-
Field Details
-
childExpressions
-
operators
-
-
Constructor Details
-
OMathExpression
public OMathExpression(int id) -
OMathExpression
-
-
Method Details
-
getExpandContent
-
isDefinedFor
-
isDefinedFor
-
isIndexChain
-
isParentesis
public boolean isParentesis() -
isCacheable
public boolean isCacheable() -
execute
-
getIndexKey
-
getChildExpressions
-
setChildExpressions
-
addChildExpression
-
unwrapIfNeeded
-
getOperators
-
addOperator
-
toString
- Specified by:
toStringin classSimpleNode
-
toGenericStatement
- Specified by:
toGenericStatementin classSimpleNode
-
supportsBasicCalculation
protected boolean supportsBasicCalculation() -
isIndexedFunctionCall
public boolean isIndexedFunctionCall() -
estimateIndexedFunction
public long estimateIndexedFunction(OFromClause target, OCommandContext context, OBinaryCompareOperator operator, Object right) -
executeIndexedFunction
public Iterable<OIdentifiable> executeIndexedFunction(OFromClause target, OCommandContext context, OBinaryCompareOperator operator, Object right) -
canExecuteIndexedFunctionWithoutIndex
public boolean canExecuteIndexedFunctionWithoutIndex(OFromClause target, OCommandContext context, OBinaryCompareOperator operator, Object right) tests if current expression is an indexed function AND that function can also be executed without using the index- Parameters:
target- the query targetcontext- the execution context- Returns:
- true if current expression is an indexed function AND that function can also be executed without using the index, false otherwise
-
allowsIndexedFunctionExecutionOnTarget
public boolean allowsIndexedFunctionExecutionOnTarget(OFromClause target, OCommandContext context, OBinaryCompareOperator operator, Object right) tests if current expression is an indexed function AND that function can be used on this target- Parameters:
target- the query targetcontext- the execution context- Returns:
- true if current expression is an indexed function AND that function can be used on this target, false otherwise
-
executeIndexedFunctionAfterIndexSearch
public boolean executeIndexedFunctionAfterIndexSearch(OFromClause target, OCommandContext context, OBinaryCompareOperator operator, Object right) tests if current expression is an indexed function AND the function has also to be executed after the index search. In some cases, the index search is accurate, so this condition can be excluded from further evaluation. In other cases the result from the index is a superset of the expected result, so the function has to be executed anyway for further filtering- Parameters:
target- the query targetcontext- the execution context- Returns:
- true if current expression is an indexed function AND the function has also to be executed after the index search.
-
isFunctionAny
public boolean isFunctionAny() -
isFunctionAll
public boolean isFunctionAll() -
isBaseIdentifier
public boolean isBaseIdentifier() -
getPath
-
getCollate
-
isEarlyCalculated
-
needsAliases
-
isExpand
public boolean isExpand() -
isAggregate
public boolean isAggregate() -
isCount
public boolean isCount() -
splitForAggregation
-
getAggregationContext
-
copy
- Overrides:
copyin classSimpleNode
-
extractSubQueries
-
extractSubQueries
-
refersToParent
public boolean refersToParent() -
equals
-
hashCode
public int hashCode() -
getMatchPatternInvolvedAliases
-
applyRemove
-
deserializeFromResult
-
serialize
-
deserialize
-
isSelf
public boolean isSelf()
-