Interface ReactiveStreamsJpaSpecificationExecutor<T>
-
- Type Parameters:
T
- The entity type
- All Known Subinterfaces:
ReactorJpaSpecificationExecutor<T>
public interface ReactiveStreamsJpaSpecificationExecutor<T>
Interface representing reactive streams version ofJpaSpecificationExecutor
.- Since:
- 3.2
- Author:
- Denis Stepanov
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description org.reactivestreams.Publisher<java.lang.Long>
count(PredicateSpecification<T> spec)
Returns the number of instances that the givenQuerySpecification
will return.org.reactivestreams.Publisher<java.lang.Long>
count(QuerySpecification<T> spec)
Returns the number of instances that the givenQuerySpecification
will return.org.reactivestreams.Publisher<java.lang.Long>
deleteAll(DeleteSpecification<T> spec)
Deletes all entities matching the givenDeleteSpecification
.org.reactivestreams.Publisher<java.lang.Long>
deleteAll(PredicateSpecification<T> spec)
Deletes all entities matching the givenPredicateSpecification
.org.reactivestreams.Publisher<java.lang.Boolean>
exists(PredicateSpecification<T> spec)
Returns whether an instance was found for the givenPredicateSpecification
.org.reactivestreams.Publisher<java.lang.Boolean>
exists(QuerySpecification<T> spec)
Returns whether an instance was found for the givenQuerySpecification
.org.reactivestreams.Publisher<T>
findAll(PredicateSpecification<T> spec)
Returns all entities matching the givenPredicateSpecification
.org.reactivestreams.Publisher<Page<T>>
findAll(PredicateSpecification<T> spec, Pageable pageable)
Returns aPage
of entities matching the givenPredicateSpecification
.org.reactivestreams.Publisher<T>
findAll(PredicateSpecification<T> spec, Sort sort)
Returns all entities matching the givenQuerySpecification
andSort
.org.reactivestreams.Publisher<T>
findAll(QuerySpecification<T> spec)
Returns all entities matching the givenQuerySpecification
.org.reactivestreams.Publisher<Page<T>>
findAll(QuerySpecification<T> spec, Pageable pageable)
Returns aPage
of entities matching the givenQuerySpecification
.org.reactivestreams.Publisher<T>
findAll(QuerySpecification<T> spec, Sort sort)
Returns all entities matching the givenQuerySpecification
andSort
.org.reactivestreams.Publisher<T>
findOne(PredicateSpecification<T> spec)
Returns a single entity matching the givenPredicateSpecification
.org.reactivestreams.Publisher<T>
findOne(QuerySpecification<T> spec)
Returns a single entity matching the givenQuerySpecification
.org.reactivestreams.Publisher<java.lang.Long>
updateAll(UpdateSpecification<T> spec)
Updates all entities matching the givenUpdateSpecification
.
-
-
-
Method Detail
-
findOne
@NonNull org.reactivestreams.Publisher<T> findOne(@Nullable QuerySpecification<T> spec)
Returns a single entity matching the givenQuerySpecification
.- Parameters:
spec
- The query specification- Returns:
- optional found result
-
findOne
@NonNull org.reactivestreams.Publisher<T> findOne(@Nullable PredicateSpecification<T> spec)
Returns a single entity matching the givenPredicateSpecification
.- Parameters:
spec
- The query specification- Returns:
- optional found result
-
findAll
@NonNull org.reactivestreams.Publisher<T> findAll(@Nullable QuerySpecification<T> spec)
Returns all entities matching the givenQuerySpecification
.- Parameters:
spec
- The query specification- Returns:
- found results
-
findAll
@NonNull org.reactivestreams.Publisher<T> findAll(@Nullable PredicateSpecification<T> spec)
Returns all entities matching the givenPredicateSpecification
.- Parameters:
spec
- The query specification- Returns:
- found results
-
findAll
@NonNull org.reactivestreams.Publisher<Page<T>> findAll(@Nullable QuerySpecification<T> spec, Pageable pageable)
Returns aPage
of entities matching the givenQuerySpecification
.- Parameters:
spec
- The query specificationpageable
- The pageable object- Returns:
- a page
-
findAll
@NonNull org.reactivestreams.Publisher<Page<T>> findAll(@Nullable PredicateSpecification<T> spec, Pageable pageable)
Returns aPage
of entities matching the givenPredicateSpecification
.- Parameters:
spec
- The query specificationpageable
- The pageable object- Returns:
- a page
-
findAll
@NonNull org.reactivestreams.Publisher<T> findAll(@Nullable QuerySpecification<T> spec, Sort sort)
Returns all entities matching the givenQuerySpecification
andSort
.- Parameters:
spec
- The query specificationsort
- The sort object- Returns:
- found results
-
findAll
@NonNull org.reactivestreams.Publisher<T> findAll(@Nullable PredicateSpecification<T> spec, Sort sort)
Returns all entities matching the givenQuerySpecification
andSort
.- Parameters:
spec
- The query specificationsort
- The sort object- Returns:
- found results
-
count
@NonNull org.reactivestreams.Publisher<java.lang.Long> count(@Nullable QuerySpecification<T> spec)
Returns the number of instances that the givenQuerySpecification
will return.- Parameters:
spec
- The query specification- Returns:
- the number of instances.
-
count
@NonNull org.reactivestreams.Publisher<java.lang.Long> count(@Nullable PredicateSpecification<T> spec)
Returns the number of instances that the givenQuerySpecification
will return.- Parameters:
spec
- The query specification- Returns:
- the number of instances.
-
exists
@NonNull org.reactivestreams.Publisher<java.lang.Boolean> exists(@Nullable QuerySpecification<T> spec)
Returns whether an instance was found for the givenQuerySpecification
.- Parameters:
spec
- The query specification- Returns:
- the number of instances.
- Since:
- 3.8
-
exists
@NonNull org.reactivestreams.Publisher<java.lang.Boolean> exists(@Nullable PredicateSpecification<T> spec)
Returns whether an instance was found for the givenPredicateSpecification
.- Parameters:
spec
- The query specification- Returns:
- the number of instances.
- Since:
- 3.8
-
deleteAll
@NonNull org.reactivestreams.Publisher<java.lang.Long> deleteAll(@Nullable DeleteSpecification<T> spec)
Deletes all entities matching the givenDeleteSpecification
.- Parameters:
spec
- The delete specification- Returns:
- the number records deleted.
-
deleteAll
@NonNull org.reactivestreams.Publisher<java.lang.Long> deleteAll(@Nullable PredicateSpecification<T> spec)
Deletes all entities matching the givenPredicateSpecification
.- Parameters:
spec
- The delete specification- Returns:
- the number records deleted.
-
updateAll
@NonNull org.reactivestreams.Publisher<java.lang.Long> updateAll(@Nullable UpdateSpecification<T> spec)
Updates all entities matching the givenUpdateSpecification
.- Parameters:
spec
- The update specification- Returns:
- the number records updated.
-
-