Top Constructors Methods
org.hibernate.query.sqm.tree.delete

public Class SqmDeleteStatement<T>

extends AbstractSqmRestrictedDmlStatement<T>
implements SqmDeleteOrUpdateStatement<T>, JpaCriteriaDelete<T>
Class Inheritance
All Implemented Interfaces
org.hibernate.query.criteria.JpaCriteriaDelete, jakarta.persistence.criteria.CriteriaDelete, jakarta.persistence.criteria.CommonAbstractCriteria, org.hibernate.query.criteria.JpaManipulationCriteria, org.hibernate.query.criteria.JpaQueryableCriteria, org.hibernate.query.criteria.JpaCteContainer, org.hibernate.query.criteria.JpaCriteriaNode, java.io.Serializable, org.hibernate.query.criteria.JpaCriteriaBase, org.hibernate.query.sqm.tree.SqmDeleteOrUpdateStatement, org.hibernate.query.sqm.tree.predicate.SqmWhereClauseContainer, org.hibernate.query.sqm.tree.SqmDmlStatement, org.hibernate.query.sqm.tree.cte.SqmCteContainer, org.hibernate.query.sqm.tree.SqmNode, org.hibernate.query.sqm.tree.SqmStatement, org.hibernate.query.sqm.tree.SqmVisitableNode, org.hibernate.query.sqm.tree.SqmQuery
Imports
java.util.Map, .Set, org.hibernate.query.criteria.JpaCriteriaDelete, org.hibernate.query.sqm.NodeBuilder, .SemanticQueryWalker, .SqmQuerySource, org.hibernate.query.sqm.tree.AbstractSqmRestrictedDmlStatement, .SqmCopyContext, .SqmDeleteOrUpdateStatement, org.hibernate.query.sqm.tree.cte.SqmCteStatement, org.hibernate.query.sqm.tree.expression.SqmParameter, org.hibernate.query.sqm.tree.from.SqmRoot, org.hibernate.query.sqm.tree.predicate.SqmWhereClause, jakarta.persistence.criteria.Expression, .Predicate

Author
Steve Ebersole

Constructor Summary

AccessConstructor and Description
public
SqmDeleteStatement(SqmRoot<T> target, SqmQuerySource querySource, NodeBuilder nodeBuilder)

public
SqmDeleteStatement(Class<T> targetEntity, SqmQuerySource querySource, NodeBuilder nodeBuilder)

public
SqmDeleteStatement(NodeBuilder builder, SqmQuerySource querySource, Set<SqmParameter<?>> parameters, Map<String, SqmCteStatement<?>> cteStatements, SqmRoot<T> target)

Method Summary

Modifier and TypeMethod and Description
public <X> X
accept(SemanticQueryWalker<X> walker)

Implements org.hibernate.query.sqm.tree.SqmVisitableNode.accept.

Accept the walker per visitation
public void
public SqmDeleteStatement<T>
public SqmDeleteStatement<T>
where(Expression<Boolean>
a simple or compound boolean expression
restriction
)

Implements jakarta.persistence.criteria.CriteriaDelete.where.

Modify the delete query to restrict the target of the deletion according to the specified boolean expression.
public SqmDeleteStatement<T>
where(Predicate...
zero or more restriction predicates
restrictions
)

Implements jakarta.persistence.criteria.CriteriaDelete.where.

Modify the delete query to restrict the target of the deletion according to the conjunction of the specified restriction predicates.
Inherited from org.hibernate.query.sqm.tree.AbstractSqmRestrictedDmlStatement:
applyPredicatecopyWhereClausefromfromgetRestrictiongetRootgetWhereClauseinitAndGetWhereClausesetWheresetWheresetWhereClause

Constructor Detail

SqmDeleteStatementback to summary
public SqmDeleteStatement(SqmRoot<T> target, SqmQuerySource querySource, NodeBuilder nodeBuilder)
SqmDeleteStatementback to summary
public SqmDeleteStatement(Class<T> targetEntity, SqmQuerySource querySource, NodeBuilder nodeBuilder)
SqmDeleteStatementback to summary
public SqmDeleteStatement(NodeBuilder builder, SqmQuerySource querySource, Set<SqmParameter<?>> parameters, Map<String, SqmCteStatement<?>> cteStatements, SqmRoot<T> target)

Method Detail

acceptback to summary
public <X> X accept(SemanticQueryWalker<X> walker)

Implements org.hibernate.query.sqm.tree.SqmVisitableNode.accept.

Doc from org.hibernate.query.sqm.tree.SqmVisitableNode.accept.

Accept the walker per visitation

Annotations
@Override
appendHqlStringback to summary
public void appendHqlString(StringBuilder sb)

Overrides org.hibernate.query.sqm.tree.AbstractSqmRestrictedDmlStatement.appendHqlString.

Implements org.hibernate.query.sqm.tree.SqmVisitableNode.appendHqlString.

Annotations
@Override
copyback to summary
public SqmDeleteStatement<T> copy(SqmCopyContext context)

Implements org.hibernate.query.sqm.tree.SqmStatement.copy, org.hibernate.query.sqm.tree.SqmNode.copy.

Annotations
@Override
whereback to summary
public SqmDeleteStatement<T> where(Expression<Boolean> restriction)

Implements jakarta.persistence.criteria.CriteriaDelete.where.

Doc from jakarta.persistence.criteria.CriteriaDelete.where.

Modify the delete query to restrict the target of the deletion according to the specified boolean expression. Replaces the previously added restriction(s), if any.

Parameters
restriction:Expression<Boolean>

a simple or compound boolean expression

Returns:SqmDeleteStatement<T>

the modified delete query

Annotations
@Override
whereback to summary
public SqmDeleteStatement<T> where(Predicate... restrictions)

Implements jakarta.persistence.criteria.CriteriaDelete.where.

Doc from jakarta.persistence.criteria.CriteriaDelete.where.

Modify the delete query to restrict the target of the deletion according to the conjunction of the specified restriction predicates. Replaces the previously added restriction(s), if any. If no restrictions are specified, any previously added restrictions are simply removed.

Parameters
restrictions:Predicate[]

zero or more restriction predicates

Returns:SqmDeleteStatement<T>

the modified delete query

Annotations
@Override