Class EclipseLinkJPQLQueryContext
- java.lang.Object
-
- org.eclipse.persistence.jpa.jpql.tools.JPQLQueryContext
-
- org.eclipse.persistence.jpa.jpql.tools.EclipseLinkJPQLQueryContext
-
public class EclipseLinkJPQLQueryContext extends JPQLQueryContext
This context is used to store information related to the JPQL query. It supports the EclipseLink extension over the default JPQL grammar.
If the JPQL query is already parsed, then the context can use it and it needs to be set before setting theIQuery
externalQuery = ...; JPQLQueryContext context = new JPQLQueryContext(DefaultJPQLGrammar.instance()); context.setQuery(query);IQuery
:JPQLExpression
jpqlExpression = ...; JPQLQueryContext context = new JPQLQueryContext(DefaultJPQLGrammar.instance()); context.setJPQLExpression(jpqlExpression); context.setQuery(query);- Version:
- 2.4
- Author:
- Pascal Filion
- Since:
- 2.4
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.eclipse.persistence.jpa.jpql.tools.JPQLQueryContext
JPQLQueryContext.InputParameterVisitor, JPQLQueryContext.QueryExpressionVisitor
-
-
Field Summary
-
Fields inherited from class org.eclipse.persistence.jpa.jpql.tools.JPQLQueryContext
currentContext, parent
-
-
Constructor Summary
Constructors Modifier Constructor Description EclipseLinkJPQLQueryContext(JPQLGrammar jpqlGrammar)
Creates a newEclipseLinkJPQLQueryContext
.protected
EclipseLinkJPQLQueryContext(JPQLQueryContext parent, Expression currentQuery)
Creates a newEclipseLinkJPQLQueryContext
.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected DeclarationResolver
buildDeclarationResolver(DeclarationResolver parent)
protected JPQLQueryContext
buildJPQLQueryContext(JPQLQueryContext currentContext, Expression currentQuery)
protected LiteralVisitor
buildLiteralVisitor()
protected EclipseLinkParameterTypeVisitor
buildParameterTypeVisitor()
protected ResolverBuilder
buildResolverBuilder()
EclipseLinkJPQLQueryContext
getParent()
Returns the parent context if the current context is not the root context.-
Methods inherited from class org.eclipse.persistence.jpa.jpql.tools.JPQLQueryContext
buildDeclarationResolver, buildInputParameter, buildQueryExpressionVisitor, convertUnqualifiedDeclaration, dispose, disposeSubqueryContext, findInputParameters, getActualCurrentQuery, getActualDeclarationResolver, getCurrentContext, getCurrentQuery, getDeclaration, getDeclarationResolver, getDeclarationResolver, getDeclarationResolverImp, getDeclarations, getEnumType, getExpressionRegistry, getGrammar, getInputParameterVisitor, getJPAVersion, getJPQLExpression, getJPQLQuery, getLiteralVisitor, getMapping, getParameterType, getParameterTypeVisitor, getProvider, getProviderVersion, getQuery, getQueryExpression, getQueryExpressionVisitor, getResolver, getResolver, getResolverBuilder, getResultVariables, getType, getType, getType, getTypeDeclaration, getTypeHelper, getTypeRepository, hasJoins, initialize, initializeRoot, isCollectionIdentificationVariable, isRangeIdentificationVariable, isResultVariable, isSubquery, isTolerant, literal, newSubqueryContext, setJPQLExpression, setQuery, setTolerant, store, toString
-
-
-
-
Constructor Detail
-
EclipseLinkJPQLQueryContext
public EclipseLinkJPQLQueryContext(JPQLGrammar jpqlGrammar)
Creates a newEclipseLinkJPQLQueryContext
.- Parameters:
jpqlGrammar
- The grammar that defines how to parse a JPQL query
-
EclipseLinkJPQLQueryContext
protected EclipseLinkJPQLQueryContext(JPQLQueryContext parent, Expression currentQuery)
Creates a newEclipseLinkJPQLQueryContext
.- Parameters:
parent
- The parent contextcurrentQuery
- The parsed tree representation of the subquery
-
-
Method Detail
-
buildDeclarationResolver
protected DeclarationResolver buildDeclarationResolver(DeclarationResolver parent)
- Overrides:
buildDeclarationResolver
in classJPQLQueryContext
-
buildJPQLQueryContext
protected JPQLQueryContext buildJPQLQueryContext(JPQLQueryContext currentContext, Expression currentQuery)
- Specified by:
buildJPQLQueryContext
in classJPQLQueryContext
-
buildLiteralVisitor
protected LiteralVisitor buildLiteralVisitor()
- Specified by:
buildLiteralVisitor
in classJPQLQueryContext
-
buildParameterTypeVisitor
protected EclipseLinkParameterTypeVisitor buildParameterTypeVisitor()
- Specified by:
buildParameterTypeVisitor
in classJPQLQueryContext
-
buildResolverBuilder
protected ResolverBuilder buildResolverBuilder()
- Specified by:
buildResolverBuilder
in classJPQLQueryContext
-
getParent
public EclipseLinkJPQLQueryContext getParent()
Returns the parent context if the current context is not the root context.- Overrides:
getParent
in classJPQLQueryContext
- Returns:
- The parent context or
null
if the current context is the root
-
-