Uses of Interface
org.springframework.data.jpa.domain.PredicateSpecification
Packages that use PredicateSpecification
Package
Description
JPA specific support classes to implement domain classes.
Interfaces and annotations for JPA specific repositories.
-
Uses of PredicateSpecification in org.springframework.data.jpa.domain
Methods in org.springframework.data.jpa.domain that return PredicateSpecificationModifier and TypeMethodDescriptionstatic <T> PredicateSpecification
<T> PredicateSpecification.allOf
(Iterable<PredicateSpecification<T>> specifications) Applies an AND operation to all the givenPredicateSpecification
s.static <T> PredicateSpecification
<T> PredicateSpecification.allOf
(PredicateSpecification<T>... specifications) Applies an AND operation to all the givenPredicateSpecification
s.default PredicateSpecification
<T> PredicateSpecification.and
(PredicateSpecification<T> other) ANDs the given PredicateSpecification to the current one.static <T> PredicateSpecification
<T> PredicateSpecification.anyOf
(Iterable<PredicateSpecification<T>> specifications) Applies an OR operation to all the givenPredicateSpecification
s.static <T> PredicateSpecification
<T> PredicateSpecification.anyOf
(PredicateSpecification<T>... specifications) Applies an OR operation to all the givenPredicateSpecification
s.static <T> PredicateSpecification
<T> PredicateSpecification.not
(PredicateSpecification<T> spec) Negates the givenPredicateSpecification
.default PredicateSpecification
<T> PredicateSpecification.or
(PredicateSpecification<T> other) ORs the given specification to the current one.static <T> PredicateSpecification
<T> PredicateSpecification.unrestricted()
Simple static factory method to create a specification which does not participate in matching.static <T> PredicateSpecification
<T> PredicateSpecification.where
(PredicateSpecification<T> spec) Simple static factory method to add some syntactic sugar around a PredicateSpecification.Methods in org.springframework.data.jpa.domain with parameters of type PredicateSpecificationModifier and TypeMethodDescriptionstatic <T> PredicateSpecification
<T> PredicateSpecification.allOf
(PredicateSpecification<T>... specifications) Applies an AND operation to all the givenPredicateSpecification
s.default DeleteSpecification
<T> DeleteSpecification.and
(PredicateSpecification<T> other) ANDs the givenDeleteSpecification
to the current one.default PredicateSpecification
<T> PredicateSpecification.and
(PredicateSpecification<T> other) ANDs the given PredicateSpecification to the current one.default Specification
<T> Specification.and
(PredicateSpecification<T> other) ANDs the givenSpecification
to the current one.default UpdateSpecification
<T> UpdateSpecification.and
(PredicateSpecification<T> other) ANDs the givenUpdateSpecification
to the current one.static <T> PredicateSpecification
<T> PredicateSpecification.anyOf
(PredicateSpecification<T>... specifications) Applies an OR operation to all the givenPredicateSpecification
s.static <T> PredicateSpecification
<T> PredicateSpecification.not
(PredicateSpecification<T> spec) Negates the givenPredicateSpecification
.default DeleteSpecification
<T> DeleteSpecification.or
(PredicateSpecification<T> other) ORs the given specification to the current one.default PredicateSpecification
<T> PredicateSpecification.or
(PredicateSpecification<T> other) ORs the given specification to the current one.default Specification
<T> Specification.or
(PredicateSpecification<T> other) ORs the given specification to the current one.default UpdateSpecification
<T> UpdateSpecification.or
(PredicateSpecification<T> other) ORs the given specification to the current one.static <T> DeleteSpecification
<T> DeleteSpecification.where
(PredicateSpecification<T> spec) Simple static factory method to add some syntactic sugar translatingPredicateSpecification
toDeleteSpecification
.static <T> PredicateSpecification
<T> PredicateSpecification.where
(PredicateSpecification<T> spec) Simple static factory method to add some syntactic sugar around a PredicateSpecification.static <T> Specification
<T> Specification.where
(PredicateSpecification<T> spec) Simple static factory method to add some syntactic sugar translatingPredicateSpecification
toSpecification
.default UpdateSpecification
<T> UpdateSpecification.UpdateOperation.where
(PredicateSpecification<T> specification) Creates aUpdateSpecification
from this and the givenUpdateSpecification
.static <T> UpdateSpecification
<T> UpdateSpecification.where
(PredicateSpecification<T> spec) Simple static factory method to add some syntactic sugar translatingPredicateSpecification
toUpdateSpecification
.Method parameters in org.springframework.data.jpa.domain with type arguments of type PredicateSpecificationModifier and TypeMethodDescriptionstatic <T> PredicateSpecification
<T> PredicateSpecification.allOf
(Iterable<PredicateSpecification<T>> specifications) Applies an AND operation to all the givenPredicateSpecification
s.static <T> PredicateSpecification
<T> PredicateSpecification.anyOf
(Iterable<PredicateSpecification<T>> specifications) Applies an OR operation to all the givenPredicateSpecification
s. -
Uses of PredicateSpecification in org.springframework.data.jpa.repository
Methods in org.springframework.data.jpa.repository with parameters of type PredicateSpecificationModifier and TypeMethodDescriptiondefault long
JpaSpecificationExecutor.count
(PredicateSpecification<T> spec) Returns the number of instances that the givenPredicateSpecification
will return.default long
JpaSpecificationExecutor.delete
(PredicateSpecification<T> spec) Deletes by thePredicateSpecification
and returns the number of rows deleted.default boolean
JpaSpecificationExecutor.exists
(PredicateSpecification<T> spec) Checks whether the data store contains elements that match the givenPredicateSpecification
.JpaSpecificationExecutor.findAll
(PredicateSpecification<T> spec) Returns all entities matching the givenPredicateSpecification
.default <S extends T, R>
RJpaSpecificationExecutor.findBy
(PredicateSpecification<T> spec, Function<? super JpaSpecificationExecutor.SpecificationFluentQuery<S>, R> queryFunction) Returns entities matching the givenSpecification
applying thequeryFunction
that defines the query and its result type.JpaSpecificationExecutor.findOne
(PredicateSpecification<T> spec) Returns a single entity matching the givenPredicateSpecification
orOptional.empty()
if none found.JpaSpecificationExecutor.SpecificationFluentQuery.page
(Pageable pageable, PredicateSpecification<?> countSpec) Get a page of matching elements forPageable
and provide a customcount specification
.