Skip to content

Commit

Permalink
Fix BasicRepository.findAll after losing its sort criteria to jakarta…
Browse files Browse the repository at this point in the history
…ee#639

Signed-off-by: Nathan Rauh <[email protected]>
  • Loading branch information
njr-11 committed Apr 4, 2024
1 parent 0fc56af commit f369f5d
Showing 1 changed file with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
*/
package jakarta.data.repository;

import jakarta.data.Order;
import jakarta.data.exceptions.OptimisticLockingFailureException;
import jakarta.data.page.Page;
import jakarta.data.page.PageRequest;
Expand Down Expand Up @@ -160,14 +161,15 @@ public interface BasicRepository<T, K> extends DataRepository<T, K> {
* Returns a {@link Page} of entities according to the page request that is provided as the {@link PageRequest} parameter.
*
* @param pageRequest the request for a paginated result; must not be {@code null}.
* @param sortBy sort criteria that must deterministically order the results; must not be {@code null}.
* @return a page of entities; will never be {@code null}.
* @throws NullPointerException when {@code pageRequest} is {@code null}.
* @throws NullPointerException when {@code pageRequest} or {@code sortBy} is {@code null}.
* @throws UnsupportedOperationException for Key-Value and Wide-Column databases when the {@link PageRequest.Mode#CURSOR_NEXT}
* or {@link PageRequest.Mode#CURSOR_PREVIOUS} pagination mode is selected.
* @see PageRequest.Mode
*/
@Find
Page<T> findAll(PageRequest pageRequest);
Page<T> findAll(PageRequest pageRequest, Order<T> sortBy);

/**
* Deletes the entity with the given Id.
Expand Down

0 comments on commit f369f5d

Please sign in to comment.