| Modifier and Type | Field and Description |
|---|---|
| protected String | |
| protected Expression | |
| protected boolean | |
| protected Class | |
| protected ReportQuery |
| Access | Constructor and Description |
|---|---|
| public | |
| public |
| Modifier and Type | Method and Description |
|---|---|
| public static SubSelectExpression | createSubSelectExpressionForCount(Expression outerQueryBaseExpression, Expression outerQueryCriteria, String attribute, Class<?> returnType)
INTERNAL: This factory method is used to build a subselect that will do a count. |
| public String | descriptionOfNodeType()
Overrides org. |
| public boolean | equals(Object
the reference object with which to compare. object)Overrides org. |
| public ReportQuery | |
| protected void | initializeCountSubQuery()
INTERNAL: This method creates a report query that counts the number of values in baseExpression.anyOf(attribute) For most queries, a ReportQuery will be created that does a simple count using an anonymous query. |
| public boolean | isSubSelectExpression()
Overrides org. |
| public void | iterateOn(ExpressionIterator iterator)
Overrides org. |
| public Expression | normalize(ExpressionNormalizer normalizer)
Overrides org. |
| public Expression | normalizeSubSelect(ExpressionNormalizer normalizer, Map<K, V> clonedExpressions)
INTERNAL: Normalize this expression now that the parent statement has been normalized. |
| protected void | postCopyIn(Map<K, V> alreadyDone)
Overrides org. |
| protected void | |
| public void | printSQL(ExpressionSQLPrinter printer)
Implements abstract org. |
| public Expression | rebuildOn(Expression newBase)
Implements abstract org. |
| public void | resetPlaceHolderBuilder(ExpressionBuilder queryBuilder)
Overrides org. |
| public void | |
| public Expression | twistedForBaseAndContext(Expression newBase, Expression context, Expression oldBase)
Overrides org. |
| public void | writeDescriptionOn(BufferedWriter writer)
Overrides org. |
| public void | writeFields(ExpressionSQLPrinter printer, List<DatabaseField> newFields, SQLSelectStatement statement)
Overrides org. |
| public void | writeSubexpressionsTo(BufferedWriter writer, int indent)
Overrides org. |
| attribute | back to summary |
|---|---|
| protected String attribute | |
| criteriaBase | back to summary |
|---|---|
| protected Expression criteriaBase | |
| hasBeenNormalized | back to summary |
|---|---|
| protected boolean hasBeenNormalized | |
| returnType | back to summary |
|---|---|
| protected Class<?> returnType | |
| subQuery | back to summary |
|---|---|
| protected ReportQuery subQuery | |
| SubSelectExpression | back to summary |
|---|---|
| public SubSelectExpression() | |
| SubSelectExpression | back to summary |
|---|---|
| public SubSelectExpression(ReportQuery query, Expression baseExpression) | |
| createSubSelectExpressionForCount | back to summary |
|---|---|
| public static SubSelectExpression createSubSelectExpressionForCount(Expression outerQueryBaseExpression, Expression outerQueryCriteria, String attribute, Class<?> returnType) INTERNAL: This factory method is used to build a subselect that will do a count. It will count the number of items in baseExpression.anyOf(attribute). | |
| descriptionOfNodeType | back to summary |
|---|---|
| public String descriptionOfNodeType() Overrides org. INTERNAL: Used in debug printing of this node.
| |
| equals | back to summary |
|---|---|
| public boolean equals(Object object) Overrides org. INTERNAL: Return if the expression is equal to the other. This is used to allow dynamic expression's SQL to be cached.
| |
| getSubQuery | back to summary |
|---|---|
| public ReportQuery getSubQuery() | |
| initializeCountSubQuery | back to summary |
|---|---|
| protected void initializeCountSubQuery() INTERNAL: This method creates a report query that counts the number of values in baseExpression.anyOf(attribute) For most queries, a ReportQuery will be created that does a simple count using an anonymous query. In the case of a DirectCollectionMapping, the ReportQuery will use the baseExpression to create a join to the table containing the Direct fields and count based on that join. | |
| isSubSelectExpression | back to summary |
|---|---|
| public boolean isSubSelectExpression() Overrides org. INTERNAL:
| |
| iterateOn | back to summary |
|---|---|
| public void iterateOn(ExpressionIterator iterator) Overrides org. INTERNAL: For iterating using an inner class
| |
| normalize | back to summary |
|---|---|
| public Expression normalize(ExpressionNormalizer normalizer) Overrides org. INTERNAL: The subquery must be normalized with the knowledge of the outer statement for outer references and correct aliasing. For CR#4223 it will now be normalized after the outer statement is, rather than somewhere in the middle of the outer statement's normalize.
| |
| normalizeSubSelect | back to summary |
|---|---|
| public Expression normalizeSubSelect(ExpressionNormalizer normalizer, Map<K, V> clonedExpressions) INTERNAL: Normalize this expression now that the parent statement has been normalized. For CR#4223 | |
| postCopyIn | back to summary |
|---|---|
| protected void postCopyIn(Map<K, V> alreadyDone) Overrides org. The query must be cloned, and the sub-expression must be cloned using the same outer expression identity.
| |
| printCustomSQL | back to summary |
|---|---|
| protected void printCustomSQL(ExpressionSQLPrinter printer) Print the sub query to the printer. | |
| printSQL | back to summary |
|---|---|
| public void printSQL(ExpressionSQLPrinter printer) Implements abstract org. Print the sub query to the printer.
| |
| rebuildOn | back to summary |
|---|---|
| public Expression rebuildOn(Expression newBase) Implements abstract org. Should not rebuild as has its on expression builder.
| |
| resetPlaceHolderBuilder | back to summary |
|---|---|
| public void resetPlaceHolderBuilder(ExpressionBuilder queryBuilder) Overrides org. INTERNAL: Search the tree for any expressions (like SubSelectExpressions) that have been built using a builder that is not attached to the query. This happens in case of an Exists call using a new ExpressionBuilder(). This builder needs to be replaced with one from the query.
| |
| setSubQuery | back to summary |
|---|---|
| public void setSubQuery(ReportQuery subQuery) | |
| twistedForBaseAndContext | back to summary |
|---|---|
| public Expression twistedForBaseAndContext(Expression newBase, Expression context, Expression oldBase) Overrides org. Doc from org. INTERNAL: Rebuild myself against the base, with the values of parameters supplied by the context expression. This is used for transforming a standalone expression (e.g. the join criteria of a mapping) into part of some larger expression. You normally would not call this directly, instead calling twist See the comment there for more details"
| |
| writeDescriptionOn | back to summary |
|---|---|
| public void writeDescriptionOn(BufferedWriter writer) throws IOException Overrides org. INTERNAL: Used to print a debug form of the expression tree.
| |
| writeFields | back to summary |
|---|---|
| public void writeFields(ExpressionSQLPrinter printer, List<DatabaseField> newFields, SQLSelectStatement statement) Overrides org. INTERNAL: called from SQLSelectStatement.writeFieldsFromExpression(...) This allows a sub query in the select clause.
| |
| writeSubexpressionsTo | back to summary |
|---|---|
| public void writeSubexpressionsTo(BufferedWriter writer, int indent) throws IOException Overrides org. INTERNAL: Used in SQL printing.
| |