Interface PersistentEntityCriteriaQuery<T>

Type Parameters:
T - The entity type
All Superinterfaces:
jakarta.persistence.criteria.AbstractQuery<T>, jakarta.persistence.criteria.CommonAbstractCriteria, jakarta.persistence.criteria.CriteriaQuery<T>, PersistentEntityCommonAbstractCriteria, PersistentEntityQuery<T>
All Known Subinterfaces:
SourcePersistentEntityCriteriaQuery<T>
All Known Implementing Classes:
AbstractPersistentEntityCriteriaQuery

public interface PersistentEntityCriteriaQuery<T> extends jakarta.persistence.criteria.CriteriaQuery<T>, PersistentEntityQuery<T>
The persistent entity CriteriaQuery.
Since:
3.2
Author:
Denis Stepanov
  • Method Details

    • from

      @NonNull <X> @NonNull PersistentEntityRoot<X> from(@NonNull @NonNull PersistentEntity persistentEntity)
      Description copied from interface: PersistentEntityQuery
      Create a root using PersistentEntity.
      Specified by:
      from in interface PersistentEntityQuery<T>
      Type Parameters:
      X - The root type
      Parameters:
      persistentEntity - The persistent entity
      Returns:
      The root
    • from

      @NonNull <X> @NonNull PersistentEntityRoot<X> from(@NonNull @NonNull Class<X> entityClass)
      Specified by:
      from in interface jakarta.persistence.criteria.AbstractQuery<T>
    • from

      @NonNull <X> @NonNull PersistentEntityRoot<X> from(@NonNull @NonNull jakarta.persistence.metamodel.EntityType<X> entity)
      Specified by:
      from in interface jakarta.persistence.criteria.AbstractQuery<T>
    • limit

      @NonNull @NonNull PersistentEntityCriteriaQuery<T> limit(int limit)
      Description copied from interface: PersistentEntityQuery
      Sets the limit to the query.
      Specified by:
      limit in interface PersistentEntityQuery<T>
      Parameters:
      limit - The limit
      Returns:
      The query
    • offset

      @NonNull @NonNull PersistentEntityCriteriaQuery<T> offset(int offset)
      Description copied from interface: PersistentEntityQuery
      Sets the offset to the query.
      Specified by:
      offset in interface PersistentEntityQuery<T>
      Parameters:
      offset - The offset
      Returns:
      The query
    • forUpdate

      @Internal @NonNull default @NonNull PersistentEntityCriteriaQuery<T> forUpdate(boolean forUpdate)
    • select

      @NonNull @NonNull PersistentEntityCriteriaQuery<T> select(@NonNull @NonNull jakarta.persistence.criteria.Selection<? extends T> selection)
      Specified by:
      select in interface jakarta.persistence.criteria.CriteriaQuery<T>
    • multiselect

      @NonNull @NonNull PersistentEntityCriteriaQuery<T> multiselect(@NonNull @NonNull jakarta.persistence.criteria.Selection<?>... selections)
      Specified by:
      multiselect in interface jakarta.persistence.criteria.CriteriaQuery<T>
    • multiselect

      @NonNull @NonNull PersistentEntityCriteriaQuery<T> multiselect(@NonNull @NonNull List<jakarta.persistence.criteria.Selection<?>> selectionList)
      Specified by:
      multiselect in interface jakarta.persistence.criteria.CriteriaQuery<T>
    • where

      @NonNull @NonNull PersistentEntityCriteriaQuery<T> where(@NonNull @NonNull jakarta.persistence.criteria.Expression<Boolean> restriction)
      Specified by:
      where in interface jakarta.persistence.criteria.AbstractQuery<T>
      Specified by:
      where in interface jakarta.persistence.criteria.CriteriaQuery<T>
    • where

      @NonNull @NonNull PersistentEntityCriteriaQuery<T> where(@NonNull @NonNull jakarta.persistence.criteria.Predicate... restrictions)
      Specified by:
      where in interface jakarta.persistence.criteria.AbstractQuery<T>
      Specified by:
      where in interface jakarta.persistence.criteria.CriteriaQuery<T>
    • groupBy

      @NonNull @NonNull PersistentEntityCriteriaQuery<T> groupBy(@NonNull @NonNull jakarta.persistence.criteria.Expression<?>... grouping)
      Specified by:
      groupBy in interface jakarta.persistence.criteria.AbstractQuery<T>
      Specified by:
      groupBy in interface jakarta.persistence.criteria.CriteriaQuery<T>
    • groupBy

      @NonNull @NonNull PersistentEntityCriteriaQuery<T> groupBy(@NonNull @NonNull List<jakarta.persistence.criteria.Expression<?>> grouping)
      Specified by:
      groupBy in interface jakarta.persistence.criteria.AbstractQuery<T>
      Specified by:
      groupBy in interface jakarta.persistence.criteria.CriteriaQuery<T>
    • having

      @NonNull @NonNull PersistentEntityCriteriaQuery<T> having(@NonNull @NonNull jakarta.persistence.criteria.Expression<Boolean> restriction)
      Specified by:
      having in interface jakarta.persistence.criteria.AbstractQuery<T>
      Specified by:
      having in interface jakarta.persistence.criteria.CriteriaQuery<T>
    • having

      @NonNull @NonNull PersistentEntityCriteriaQuery<T> having(@NonNull @NonNull jakarta.persistence.criteria.Predicate... restrictions)
      Specified by:
      having in interface jakarta.persistence.criteria.AbstractQuery<T>
      Specified by:
      having in interface jakarta.persistence.criteria.CriteriaQuery<T>
    • orderBy

      @NonNull @NonNull PersistentEntityCriteriaQuery<T> orderBy(@NonNull @NonNull jakarta.persistence.criteria.Order... orders)
      Description copied from interface: PersistentEntityQuery
      Ordering of the query.
      Specified by:
      orderBy in interface jakarta.persistence.criteria.CriteriaQuery<T>
      Specified by:
      orderBy in interface PersistentEntityQuery<T>
      Parameters:
      orders - The order
      Returns:
      The query
    • orderBy

      @NonNull @NonNull PersistentEntityCriteriaQuery<T> orderBy(@NonNull @NonNull List<jakarta.persistence.criteria.Order> orders)
      Description copied from interface: PersistentEntityQuery
      Ordering of the query.
      Specified by:
      orderBy in interface jakarta.persistence.criteria.CriteriaQuery<T>
      Specified by:
      orderBy in interface PersistentEntityQuery<T>
      Parameters:
      orders - The order
      Returns:
      The query
    • distinct

      @NonNull @NonNull PersistentEntityCriteriaQuery<T> distinct(boolean distinct)
      Specified by:
      distinct in interface jakarta.persistence.criteria.AbstractQuery<T>
      Specified by:
      distinct in interface jakarta.persistence.criteria.CriteriaQuery<T>