Class SqmQuerySpec<T>
java.lang.Object
org.hibernate.query.sqm.tree.select.SqmQueryPart<T>
org.hibernate.query.sqm.tree.select.SqmQuerySpec<T>
- All Implemented Interfaces:
Serializable
,JpaCriteriaNode
,JpaQueryPart<T>
,JpaQueryStructure<T>
,SqmFromClauseContainer
,SqmWhereClauseContainer
,SqmNode
,SqmVisitableNode
public class SqmQuerySpec<T>
extends SqmQueryPart<T>
implements SqmNode, SqmFromClauseContainer, SqmWhereClauseContainer, JpaQueryStructure<T>
Defines the commonality between a root query and a subquery.
- See Also:
-
Field Summary
-
Constructor Summary
ConstructorsConstructorDescriptionSqmQuerySpec
(NodeBuilder nodeBuilder) SqmQuerySpec
(SqmQuerySpec<T> original, SqmCopyContext context) -
Method Summary
Modifier and TypeMethodDescription<X> X
accept
(SemanticQueryWalker<X> walker) Accept the walker per visitationvoid
void
applyPredicate
(SqmPredicate predicate) boolean
copy
(SqmCopyContext context) Obtains this container's SqmFromClause.List<SqmExpression<?>>
List<SqmExpression<?>>
getRoots()
boolean
groupByClauseContains
(NavigablePath navigablePath, SqmToSqlAstConverter sqlAstConverter) boolean
boolean
boolean
boolean
orderByClauseContains
(NavigablePath navigablePath, SqmToSqlAstConverter sqlAstConverter) boolean
setDistinct
(boolean distinct) setFetch
(JpaExpression<? extends Number> fetch) setFetch
(JpaExpression<? extends Number> fetch, FetchClauseType fetchClauseType) void
setFromClause
(SqmFromClause fromClause) void
setGroupByClauseExpressions
(List<SqmExpression<?>> groupByClauseExpressions) setGroupingExpressions
(List<? extends JpaExpression<?>> groupExpressions) setGroupingExpressions
(JpaExpression<?>... groupExpressions) setGroupRestriction
(Expression<Boolean> restriction) setGroupRestriction
(Predicate... restrictions) setGroupRestriction
(JpaPredicate restriction) void
setHavingClausePredicate
(SqmPredicate havingClausePredicate) setOffset
(JpaExpression<? extends Number> offset) setRestriction
(Expression<Boolean> restriction) setRestriction
(Predicate... restrictions) setRestriction
(JpaPredicate restriction) void
setSelectClause
(SqmSelectClause selectClause) setSelection
(JpaSelection<T> selection) setSortSpecifications
(List<? extends JpaOrder> sortSpecifications) void
setWhereClause
(SqmWhereClause whereClause) void
void
boolean
whereClauseContains
(NavigablePath navigablePath, SqmToSqlAstConverter sqlAstConverter) Methods inherited from class org.hibernate.query.sqm.tree.select.SqmQueryPart
copyTo, getFetch, getFetchClauseType, getFetchExpression, getOffset, getOffsetExpression, getOrderByClause, getSortSpecifications, nodeBuilder, setFetchExpression, setFetchExpression, setOffsetExpression, setOrderByClause
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.hibernate.query.criteria.JpaQueryPart
getFetch, getFetchClauseType, getOffset, getSortSpecifications
Methods inherited from interface org.hibernate.query.sqm.tree.SqmNode
asLoggableText, nodeBuilder
Methods inherited from interface org.hibernate.query.sqm.tree.SqmVisitableNode
toHqlString
-
Constructor Details
-
SqmQuerySpec
-
SqmQuerySpec
-
-
Method Details
-
copy
- Specified by:
copy
in interfaceSqmNode
- Specified by:
copy
in classSqmQueryPart<T>
-
accept
Description copied from interface:SqmVisitableNode
Accept the walker per visitation- Specified by:
accept
in interfaceSqmVisitableNode
-
getFirstQuerySpec
- Specified by:
getFirstQuerySpec
in classSqmQueryPart<T>
-
getLastQuerySpec
- Specified by:
getLastQuerySpec
in classSqmQueryPart<T>
-
isSimpleQueryPart
public boolean isSimpleQueryPart()- Specified by:
isSimpleQueryPart
in classSqmQueryPart<T>
-
getFromClause
Description copied from interface:SqmFromClauseContainer
Obtains this container's SqmFromClause.- Specified by:
getFromClause
in interfaceSqmFromClauseContainer
- Returns:
- This container's SqmFromClause.
-
setFromClause
-
producesUniqueResults
public boolean producesUniqueResults() -
containsCollectionFetches
public boolean containsCollectionFetches() -
getSelectClause
-
setSelectClause
-
getWhereClause
- Specified by:
getWhereClause
in interfaceSqmWhereClauseContainer
-
setWhereClause
-
applyPredicate
- Specified by:
applyPredicate
in interfaceSqmWhereClauseContainer
-
hasPositionalGroupItem
public boolean hasPositionalGroupItem() -
getGroupByClauseExpressions
-
setGroupByClauseExpressions
-
getHavingClausePredicate
-
setHavingClausePredicate
-
isDistinct
public boolean isDistinct()- Specified by:
isDistinct
in interfaceJpaQueryStructure<T>
-
setDistinct
- Specified by:
setDistinct
in interfaceJpaQueryStructure<T>
-
getSelection
- Specified by:
getSelection
in interfaceJpaQueryStructure<T>
-
setSelection
- Specified by:
setSelection
in interfaceJpaQueryStructure<T>
-
getRoots
- Specified by:
getRoots
in interfaceJpaQueryStructure<T>
-
getRootList
- Specified by:
getRootList
in interfaceJpaQueryStructure<T>
-
addRoot
- Specified by:
addRoot
in interfaceJpaQueryStructure<T>
-
getRestriction
- Specified by:
getRestriction
in interfaceJpaQueryStructure<T>
-
setRestriction
- Specified by:
setRestriction
in interfaceJpaQueryStructure<T>
-
setRestriction
- Specified by:
setRestriction
in interfaceJpaQueryStructure<T>
-
setRestriction
- Specified by:
setRestriction
in interfaceJpaQueryStructure<T>
-
getGroupingExpressions
- Specified by:
getGroupingExpressions
in interfaceJpaQueryStructure<T>
-
setGroupingExpressions
- Specified by:
setGroupingExpressions
in interfaceJpaQueryStructure<T>
-
setGroupingExpressions
- Specified by:
setGroupingExpressions
in interfaceJpaQueryStructure<T>
-
getGroupRestriction
- Specified by:
getGroupRestriction
in interfaceJpaQueryStructure<T>
-
setGroupRestriction
- Specified by:
setGroupRestriction
in interfaceJpaQueryStructure<T>
-
setGroupRestriction
- Specified by:
setGroupRestriction
in interfaceJpaQueryStructure<T>
-
setGroupRestriction
- Specified by:
setGroupRestriction
in interfaceJpaQueryStructure<T>
-
setSortSpecifications
- Specified by:
setSortSpecifications
in interfaceJpaQueryPart<T>
- Specified by:
setSortSpecifications
in interfaceJpaQueryStructure<T>
- Overrides:
setSortSpecifications
in classSqmQueryPart<T>
-
setOffset
- Specified by:
setOffset
in interfaceJpaQueryPart<T>
- Specified by:
setOffset
in interfaceJpaQueryStructure<T>
- Overrides:
setOffset
in classSqmQueryPart<T>
-
setFetch
- Specified by:
setFetch
in interfaceJpaQueryPart<T>
- Specified by:
setFetch
in interfaceJpaQueryStructure<T>
- Overrides:
setFetch
in classSqmQueryPart<T>
-
setFetch
public SqmQuerySpec<T> setFetch(JpaExpression<? extends Number> fetch, FetchClauseType fetchClauseType) - Specified by:
setFetch
in interfaceJpaQueryPart<T>
- Specified by:
setFetch
in interfaceJpaQueryStructure<T>
- Overrides:
setFetch
in classSqmQueryPart<T>
-
validateQueryStructureAndFetchOwners
public void validateQueryStructureAndFetchOwners()- Specified by:
validateQueryStructureAndFetchOwners
in classSqmQueryPart<T>
-
validateFetchOwners
public void validateFetchOwners() -
appendHqlString
- Specified by:
appendHqlString
in interfaceSqmVisitableNode
- Overrides:
appendHqlString
in classSqmQueryPart<T>
-