public class SumNode extends AggregateNode
Purpose: Model a SUM
Responsibilities:
left, right, shouldGenerateExpression| Constructor and Description |
|---|
SumNode() |
| Modifier and Type | Method and Description |
|---|---|
protected Expression |
addAggregateExression(Expression expr)
INTERNAL
|
void |
applyToQuery(ObjectLevelReadQuery theQuery,
GenerationContext context)
INTERNAL
Apply this node to the passed query
|
protected java.lang.Class |
calculateReturnType(GenerationContext context)
INTERNAL
This method calculates the return type of the SUM operation.
|
protected java.lang.Object |
calculateReturnType(java.lang.Object argType,
TypeHelper helper)
INTERNAL
Helper method to calculate the return type of the SUM operation.
|
java.lang.String |
getAsString()
INTERNAL
Get the string representation of this node.
|
void |
validate(ParseTreeContext context)
INTERNAL
Validate node and calculate its type.
|
generateExpression, isAggregateNode, resolveAttribute, resolveClass, setDistinct, usesDistinctaddToExpression, appendExpression, getColumn, getLeft, getLine, getRight, getType, hasLeft, hasRight, isAttributeNode, isConstructorNode, isCountNode, isDivideNode, isDotNode, isEscape, isLiteralNode, isMinusNode, isMultiplyNode, isNotNode, isParameterNode, isPlusNode, isSubqueryNode, isVariableNode, qualifyAttributeAccess, resolveClass, resolveMapping, resolveMapping, setColumn, setLeft, setLine, setRight, setType, toString, toString, toStringDisplayName, toStringIndent, validateParameterpublic void applyToQuery(ObjectLevelReadQuery theQuery, GenerationContext context)
applyToQuery in class Nodepublic void validate(ParseTreeContext context)
protected Expression addAggregateExression(Expression expr)
addAggregateExression in class AggregateNodeprotected java.lang.Class calculateReturnType(GenerationContext context)
protected java.lang.Object calculateReturnType(java.lang.Object argType,
TypeHelper helper)
public java.lang.String getAsString()
getAsString in class Node