public interface IJPQLQueryBuilder
StateObject
representation of a JPQL
query.
Some default implementations are available:
JPQLQueryBuilder1_0
JPQLQueryBuilder2_0
EclipseLinkJPQLQueryBuilder
IManagedTypeProvider
,
StateObject
Modifier and Type | Method and Description |
---|---|
ICaseExpressionStateObjectBuilder |
buildCaseExpressionStateObjectBuilder(StateObject parent)
Creates a builder that can create a
CASE expression programmatically. |
JPQLQueryStateObject |
buildStateObject(IManagedTypeProvider provider,
java.lang.CharSequence jpqlQuery,
boolean tolerant)
Creates a state model representation of a JPQL query that can be edited.
|
JPQLQueryStateObject |
buildStateObject(IManagedTypeProvider provider,
java.lang.CharSequence jpqlQuery,
java.lang.String queryBNFId,
boolean tolerant)
Creates a state model representation of a JPQL query that can be edited.
|
StateObject |
buildStateObject(StateObject parent,
java.lang.CharSequence jpqlFragment,
java.lang.String queryBNFId)
Creates a
StateObject representation of the given JPQL fragment. |
IConditionalExpressionStateObjectBuilder |
buildStateObjectBuilder(AbstractConditionalClauseStateObject stateObject)
Creates a builder that can create a conditional expression programmatically.
|
ISelectExpressionStateObjectBuilder |
buildStateObjectBuilder(SelectClauseStateObject stateObject)
Creates a builder that can create a select expression programmatically.
|
ISimpleSelectExpressionStateObjectBuilder |
buildStateObjectBuilder(SimpleSelectClauseStateObject stateObject)
Creates a builder that can create a single select expression programmatically.
|
INewValueStateObjectBuilder |
buildStateObjectBuilder(UpdateItemStateObject stateObject)
Creates a builder that can create a new value expression programmatically.
|
JPQLGrammar |
getGrammar()
Returns the
JPQLGrammar that is associated with this builder. |
ICaseExpressionStateObjectBuilder buildCaseExpressionStateObjectBuilder(StateObject parent)
CASE
expression programmatically. Once
the expression is complete, ICaseExpressionStateObjectBuilder.buildStateObject()
will
return the result.parent
- The StateObject
that will be the parent of the newly created modelCASE
expressionJPQLQueryStateObject buildStateObject(IManagedTypeProvider provider, java.lang.CharSequence jpqlQuery, boolean tolerant)
provider
- The provider of managed typesjpqlQuery
- The JPQL query to parse into a StateObject
modeltolerant
- Determines if the parsing system should be tolerant, meaning if it should try
to parse invalid or incomplete queriesStateObject
model that represents the edited form of the JPQL queryJPQLQueryStateObject buildStateObject(IManagedTypeProvider provider, java.lang.CharSequence jpqlQuery, java.lang.String queryBNFId, boolean tolerant)
provider
- The provider of managed typesjpqlQuery
- The JPQL query to parse into a StateObject
modelqueryBNFId
- The unique identifier of the query BNF that will be used to parse the fragmenttolerant
- Determines if the parsing system should be tolerant, meaning if it should try
to parse invalid or incomplete queriesStateObject
model that represents the edited form of the JPQL queryStateObject buildStateObject(StateObject parent, java.lang.CharSequence jpqlFragment, java.lang.String queryBNFId)
StateObject
representation of the given JPQL fragment. In order to properly
parse the fragment, the given unique identifier of the parser.JPQLQueryBNF JPQLQueryBNF
will determine how to parse it.
It is possible the given JPQL fragment has more than one expression, in this case, parsing should stop at the first comma (x, y) or space (x y) where x and y are two separate expressions.
parent
- The StateObject
that will be the parent of the newly created modeljpqlFragment
- A portion of a JPQL query that will be parsed and the StateObject
representation will be createdqueryBNFId
- The unique identifier of the query BNF that will be used to parse the fragmentStateObject
representation of the given JPQL fragmentIConditionalExpressionStateObjectBuilder buildStateObjectBuilder(AbstractConditionalClauseStateObject stateObject)
IConditionalExpressionStateObjectBuilder.commit()
will push
the result onto the given state object.stateObject
- The clause for which a conditional expression can be createdISelectExpressionStateObjectBuilder buildStateObjectBuilder(SelectClauseStateObject stateObject)
ISelectExpressionStateObjectBuilder.commit()
will push the result onto the
given state object.stateObject
- The clause for which one or many select expressions can be createdISimpleSelectExpressionStateObjectBuilder buildStateObjectBuilder(SimpleSelectClauseStateObject stateObject)
ISimpleSelectExpressionStateObjectBuilder.commit()
will push
the result onto the given state object.stateObject
- The clause for which a select expression can be createdINewValueStateObjectBuilder buildStateObjectBuilder(UpdateItemStateObject stateObject)
INewValueStateObjectBuilder.commit()
will push the result
onto the given state object.stateObject
- The parent for which a new value expression can be createdJPQLGrammar getGrammar()
JPQLGrammar
that is associated with this builder.JPQLGrammar
that was used to parse the JPQL query or JPQL fragments