Class QueryNode
- java.lang.Object
-
- org.eclipse.persistence.internal.jpa.parsing.Node
-
- org.eclipse.persistence.internal.jpa.parsing.MajorNode
-
- org.eclipse.persistence.internal.jpa.parsing.QueryNode
-
- Direct Known Subclasses:
ModifyNode
,SelectNode
public abstract class QueryNode extends MajorNode
INTERNAL: This node contains the information about what kind of query is represented it's tree (e.g. Select, Update etc.) Subclasses of this node will contain query specific behavior.
-
-
Field Summary
-
Fields inherited from class org.eclipse.persistence.internal.jpa.parsing.Node
alias, left, right, shouldGenerateExpression
-
-
Constructor Summary
Constructors Constructor Description QueryNode()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description abstract void
applyToQuery(DatabaseQuery theQuery, GenerationContext context)
INTERNAL Apply this node to the passed queryabstract DatabaseQuery
createDatabaseQuery(ParseTreeContext context)
INTERNAL Returns a DatabaseQuery instance according to the kind of the query the owning ParseTree represents: SELECT, UPDATE or DELETE.abstract Expression
generateExpression(GenerationContext context)
INTERNAL Return a EclipseLink expression generated using the left nodeParseTree
getParseTree()
Class
getReferenceClass(GenerationContext genContext)
Compute the Reference class for this queryboolean
isDeleteNode()
boolean
isSelectNode()
boolean
isUpdateNode()
abstract Class
resolveClass(GenerationContext context)
Return the class represented in this node.void
setParseTree(ParseTree parseTree)
Set the parseTree-
Methods inherited from class org.eclipse.persistence.internal.jpa.parsing.MajorNode
getContext, setContext
-
Methods inherited from class org.eclipse.persistence.internal.jpa.parsing.Node
addToExpression, appendExpression, applyToQuery, getAlias, getAsString, getColumn, getLeft, getLine, getRight, getType, hasLeft, hasRight, isAggregateNode, isAliasableNode, isAttributeNode, isConstructorNode, isCountNode, isDivideNode, isDotNode, isEscape, isLiteralNode, isMapKeyNode, isMinusNode, isMultiplyNode, isNotNode, isParameterNode, isPlusNode, isSubqueryNode, isVariableNode, qualifyAttributeAccess, resolveAttribute, resolveClass, resolveMapping, resolveMapping, setAlias, setColumn, setLeft, setLine, setRight, setType, toString, toString, toStringDisplayName, toStringIndent, validate, validateParameter
-
-
-
-
Method Detail
-
createDatabaseQuery
public abstract DatabaseQuery createDatabaseQuery(ParseTreeContext context)
INTERNAL Returns a DatabaseQuery instance according to the kind of the query the owning ParseTree represents: SELECT, UPDATE or DELETE.
-
applyToQuery
public abstract void applyToQuery(DatabaseQuery theQuery, GenerationContext context)
INTERNAL Apply this node to the passed query
-
generateExpression
public abstract Expression generateExpression(GenerationContext context)
INTERNAL Return a EclipseLink expression generated using the left node- Overrides:
generateExpression
in classNode
-
getReferenceClass
public Class getReferenceClass(GenerationContext genContext)
Compute the Reference class for this query- Parameters:
genContext
-- Returns:
- the class this query is querying for
-
isSelectNode
public boolean isSelectNode()
-
isUpdateNode
public boolean isUpdateNode()
-
isDeleteNode
public boolean isDeleteNode()
-
resolveClass
public abstract Class resolveClass(GenerationContext context)
Return the class represented in this node.- Overrides:
resolveClass
in classNode
-
setParseTree
public void setParseTree(ParseTree parseTree)
Set the parseTree
-
getParseTree
public ParseTree getParseTree()
-
-