Class QuerySpec
- java.lang.Object
-
- org.hibernate.sql.ast.tree.select.QueryPart
-
- org.hibernate.sql.ast.tree.select.QuerySpec
-
- All Implemented Interfaces:
DomainResultProducer
,SqlSelectionProducer
,Expression
,PredicateContainer
,SqlAstNode
public class QuerySpec extends QueryPart implements SqlAstNode, PredicateContainer, Expression, DomainResultProducer
-
-
Method Summary
-
Methods inherited from class org.hibernate.sql.ast.tree.select.QueryPart
addSortSpecification, getFetchClauseExpression, getFetchClauseType, getOffsetClauseExpression, getSortSpecifications, hasOffsetOrFetchClause, hasPositionalSortItem, hasSortSpecifications, isRoot, setFetchClauseExpression, setOffsetClauseExpression, visitSortSpecifications
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.hibernate.sql.ast.tree.expression.Expression
createSqlSelection, getColumnReference
-
-
-
-
Method Detail
-
asSubQuery
public QuerySpec asSubQuery()
-
asRootQuery
public QuerySpec asRootQuery()
-
getFirstQuerySpec
public QuerySpec getFirstQuerySpec()
- Specified by:
getFirstQuerySpec
in classQueryPart
-
getLastQuerySpec
public QuerySpec getLastQuerySpec()
- Specified by:
getLastQuerySpec
in classQueryPart
-
visitQuerySpecs
public void visitQuerySpecs(Consumer<QuerySpec> querySpecConsumer)
- Specified by:
visitQuerySpecs
in classQueryPart
-
queryQuerySpecs
public <T> T queryQuerySpecs(Function<QuerySpec,T> querySpecConsumer)
- Specified by:
queryQuerySpecs
in classQueryPart
-
getFromClause
public FromClause getFromClause()
-
getSelectClause
public SelectClause getSelectClause()
-
getWhereClauseRestrictions
public Predicate getWhereClauseRestrictions()
-
applyPredicate
public void applyPredicate(Predicate predicate)
Description copied from interface:PredicateContainer
Apply a predicate to this container- Specified by:
applyPredicate
in interfacePredicateContainer
-
getGroupByClauseExpressions
public List<Expression> getGroupByClauseExpressions()
-
setGroupByClauseExpressions
public void setGroupByClauseExpressions(List<Expression> groupByClauseExpressions)
-
getHavingClauseRestrictions
public Predicate getHavingClauseRestrictions()
-
setHavingClauseRestrictions
public void setHavingClauseRestrictions(Predicate havingClauseRestrictions)
-
accept
public void accept(SqlAstWalker sqlTreeWalker)
- Specified by:
accept
in interfaceSqlAstNode
-
getExpressionType
public JdbcMappingContainer getExpressionType()
Description copied from interface:Expression
The type for this expression- Specified by:
getExpressionType
in interfaceExpression
-
applySqlSelections
public void applySqlSelections(DomainResultCreationState creationState)
Description copied from interface:DomainResultProducer
Used when this producer is a selection in a sub-query. The DomainResult is only needed for root query of a SELECT statement. This default impl assumes this producer is a true (Sql)Expression- Specified by:
applySqlSelections
in interfaceDomainResultProducer
-
createDomainResult
public DomainResult createDomainResult(String resultVariable, DomainResultCreationState creationState)
Description copied from interface:DomainResultProducer
Produce the domain query- Specified by:
createDomainResult
in interfaceDomainResultProducer
-
-