collection_member_declaration ::= IN(collection_valued_path_expression) [AS] identification_variablederived_collection_member_declaration ::= IN superquery_identification_variable.{single_valued_object_field.}*collection_valued_field
Example: SELECT t FROM Player p, IN (p.teams) AS t
| Modifier and Type | Field and Description |
|---|---|
| private String | asIdentifier
The actual AS identifier found in the string representation of the JPQL query. |
| private AbstractExpression | collectionValuedPathExpression
The |
| private boolean | hasLeftParenthesis
Flag used to determine if the closing parenthesis is present in the query. |
| private boolean | hasRightParenthesis
Flag used to determine if the opening parenthesis is present in the query. |
| private boolean | hasSpaceAfterAs
Determines whether a whitespace was parsed after AS. |
| private boolean | hasSpaceAfterIn
Determines whether a whitespace was parsed after IN. |
| private boolean | hasSpaceAfterRightParenthesis
Determines whether a whitespace was parsed after the right parenthesis. |
| private AbstractExpression | identificationVariable
The |
| private String | inIdentifier
The actual IN identifier found in the string representation of the JPQL query. |
| Access | Constructor and Description |
|---|---|
| public | CollectionMemberDeclaration(AbstractExpression
The parent of this expression parent)Creates a new |
| Modifier and Type | Method and Description |
|---|---|
| public void | accept(ExpressionVisitor
The visitor)ExpressionVisitor to visit this objectImplements org. Expression by the given visitor.
|
| public void | acceptChildren(ExpressionVisitor
The visitor)visitor to visit the children of this object.Implements org. Expression.
|
| protected void | addChildrenTo(Collection<Expression>
The collection used to store the children children)Overrides org. AbstractExpression to the given collection.
|
| protected void | addOrderedChildrenTo(List<Expression>
The list used to store the string representation of this children)AbstractExpressionOverrides org. AbstractExpression to the given list.
|
| public JPQLQueryBNF | findQueryBNF(Expression
The expression)Expression that is a descendant of this oneOverrides org. Implements org. JPQLQueryBNF that represents the fragment of this Expression
that was used when parsing the given Expression.
|
| public String | Returns: The AS identifier that was actually parsedReturns the actual AS identifier found in the string representation of the JPQL query, which has the actual case that was used. |
| public String | Returns: The IN identifier that was actually parsedReturns the actual IN identifier found in the string representation of the JPQL query, which has the actual case that was used. |
| public Expression | Returns: The expression representing the collection-valued path expressionReturns the |
| public Expression | Returns: The expression representing the identification variableReturns the |
| public JPQLQueryBNF | getQueryBNF()
Implements org. Expression.
|
| public boolean | Returns: true if the identifier AS was parsed; false otherwiseDetermines whether the identifier AS was parsed. |
| public boolean | Returns: true if the query has the collection-valued path expression;
false otherwiseDetermines whether the collection-valued path expression was parsed. |
| public boolean | Returns: true if the query has the identification variable; false
otherwiseDetermines whether the identification variable was parsed. |
| public boolean | Returns: true if the open parenthesis was present in the string version of the
query; false otherwiseDetermines whether the open parenthesis was parsed or not. |
| public boolean | Returns: true if the close parenthesis was present in the string version of the
query; false otherwiseDetermines whether the close parenthesis was parsed or not. |
| public boolean | Returns: true if there was a whitespace after AS; false
otherwiseDetermines whether a whitespace was found after AS. |
| public boolean | Returns: true if there was a whitespace after IN; false
otherwiseDetermines whether a whitespace was found after IN. |
| public boolean | Returns: true if there was a whitespace after the right parenthesis;
false otherwiseDetermines whether a whitespace was found after the close parenthesis. |
| public boolean | Returns: true if this collection member declaration is used as this form:
"IN collection_valued_path_expression" in a subquery; false
if it's used as this form: IN(collection_valued_path_expression)
[AS] identification_variable" in a top-level or subquery queriesDetermines whether this collection member declaration is used as a derived collection-valued path expression. |
| protected boolean | isParsingComplete(WordParser
The text to parse based on the current position of the cursor wordParser, String The word that was retrieved from the given text, which is the first word in the text word, Expression The expression)Expression that has already been parsedOverrides org. |
| protected void | parse(WordParser
The text to parse based on the current position of the cursor wordParser, boolean Determines whether the parsing system should be tolerant, meaning if it should
try to parse invalid or incomplete queries tolerant)Implements abstract org. WordParser.
|
| protected void | toParsedText(StringBuilder
The buffer used to append this writer, boolean Expression's string representationDetermines whether the string representation should represent what was parsed,
i.e. include any "virtual" whitespace (such as ending whitespace) and the actual case of the
JPQL identifiers actual)Implements abstract org. Expression, including its children,
if it has any.
|
| public String | Returns: The string representation of a section of this expressionCreates a string representation of this expression up and excluding the AS identifier. |
| asIdentifier | back to summary |
|---|---|
| private String asIdentifier The actual AS identifier found in the string representation of the JPQL query. | |
| collectionValuedPathExpression | back to summary |
|---|---|
| private AbstractExpression collectionValuedPathExpression The | |
| hasLeftParenthesis | back to summary |
|---|---|
| private boolean hasLeftParenthesis Flag used to determine if the closing parenthesis is present in the query. | |
| hasRightParenthesis | back to summary |
|---|---|
| private boolean hasRightParenthesis Flag used to determine if the opening parenthesis is present in the query. | |
| hasSpaceAfterAs | back to summary |
|---|---|
| private boolean hasSpaceAfterAs Determines whether a whitespace was parsed after AS. | |
| hasSpaceAfterIn | back to summary |
|---|---|
| private boolean hasSpaceAfterIn Determines whether a whitespace was parsed after IN. | |
| hasSpaceAfterRightParenthesis | back to summary |
|---|---|
| private boolean hasSpaceAfterRightParenthesis Determines whether a whitespace was parsed after the right parenthesis. | |
| identificationVariable | back to summary |
|---|---|
| private AbstractExpression identificationVariable The | |
| inIdentifier | back to summary |
|---|---|
| private String inIdentifier The actual IN identifier found in the string representation of the JPQL query. | |
| CollectionMemberDeclaration | back to summary |
|---|---|
| public CollectionMemberDeclaration(AbstractExpression parent) Creates a new
| |
| accept | back to summary |
|---|---|
| public void accept(ExpressionVisitor visitor) Implements org. Doc from org. Visits this
| |
| acceptChildren | back to summary |
|---|---|
| public void acceptChildren(ExpressionVisitor visitor) Implements org. Doc from org. Visits the children of this
This does not traverse the
| |
| addChildrenTo | back to summary |
|---|---|
| protected void addChildrenTo(Collection<Expression> children) Overrides org. Doc from org. Adds the children of this
| |
| addOrderedChildrenTo | back to summary |
|---|---|
| protected void addOrderedChildrenTo(List<Expression> children) Overrides org. Doc from org. Adds the children of this
| |
| findQueryBNF | back to summary |
|---|---|
| public JPQLQueryBNF findQueryBNF(Expression expression) Overrides org. Implements org. Doc from org. Retrieves the
| |
| getActualAsIdentifier | back to summary |
|---|---|
| public String getActualAsIdentifier() Returns the actual AS identifier found in the string representation of the JPQL query, which has the actual case that was used.
| |
| getActualInIdentifier | back to summary |
|---|---|
| public String getActualInIdentifier() Returns the actual IN identifier found in the string representation of the JPQL query, which has the actual case that was used.
| |
| getCollectionValuedPathExpression | back to summary |
|---|---|
| public Expression getCollectionValuedPathExpression() Returns the
| |
| getIdentificationVariable | back to summary |
|---|---|
| public Expression getIdentificationVariable() Returns the
| |
| getQueryBNF | back to summary |
|---|---|
| public JPQLQueryBNF getQueryBNF() Implements org. Doc from org. Returns the BNF of this
| |
| hasAs | back to summary |
|---|---|
| public boolean hasAs() Determines whether the identifier AS was parsed.
| |
| hasCollectionValuedPathExpression | back to summary |
|---|---|
| public boolean hasCollectionValuedPathExpression() Determines whether the collection-valued path expression was parsed.
| |
| hasIdentificationVariable | back to summary |
|---|---|
| public boolean hasIdentificationVariable() Determines whether the identification variable was parsed.
| |
| hasLeftParenthesis | back to summary |
|---|---|
| public boolean hasLeftParenthesis() Determines whether the open parenthesis was parsed or not.
| |
| hasRightParenthesis | back to summary |
|---|---|
| public boolean hasRightParenthesis() Determines whether the close parenthesis was parsed or not.
| |
| hasSpaceAfterAs | back to summary |
|---|---|
| public boolean hasSpaceAfterAs() Determines whether a whitespace was found after AS.
| |
| hasSpaceAfterIn | back to summary |
|---|---|
| public boolean hasSpaceAfterIn() Determines whether a whitespace was found after IN.
| |
| hasSpaceAfterRightParenthesis | back to summary |
|---|---|
| public boolean hasSpaceAfterRightParenthesis() Determines whether a whitespace was found after the close parenthesis.
| |
| isDerived | back to summary |
|---|---|
| public boolean isDerived() Determines whether this collection member declaration is used as a derived collection-valued path expression.
| |
| isParsingComplete | back to summary |
|---|---|
| protected boolean isParsingComplete(WordParser wordParser, String word, Expression expression) Overrides org. Doc from org. Determines whether the parsing is complete based on what is left in the given text. The text is never empty.
| |
| parse | back to summary |
|---|---|
| protected void parse(WordParser wordParser, boolean tolerant) Implements abstract org. Doc from org. Parses the query by starting at the current position, which is part of the given
| |
| toParsedText | back to summary |
|---|---|
| protected void toParsedText(StringBuilder writer, boolean actual) Implements abstract org. Doc from org. Generates a string representation of this
| |
| toParsedTextUntilAs | back to summary |
|---|---|
| public String toParsedTextUntilAs() Creates a string representation of this expression up and excluding the AS identifier.
| |