Class KeysetScrollDelegate
java.lang.Object
org.springframework.data.jpa.repository.query.KeysetScrollDelegate
Delegate for keyset scrolling.
- Since:
- 3.1
- Author:
- Mark Paluch
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic interface
Adapter to construct scroll queries. -
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescription<E,
P> P createPredicate
(org.springframework.data.domain.KeysetScrollPosition keyset, org.springframework.data.domain.Sort sort, KeysetScrollDelegate.QueryStrategy<E, P> strategy) protected <T> List<T>
getResultWindow
(List<T> list, int limit) protected org.springframework.data.domain.Sort
getSortOrders
(org.springframework.data.domain.Sort sort) static KeysetScrollDelegate
of
(org.springframework.data.domain.ScrollPosition.Direction direction) Factory method to obtain the rightKeysetScrollDelegate
.protected <T> List<T>
postProcessResults
(List<T> result)
-
Constructor Details
-
KeysetScrollDelegate
public KeysetScrollDelegate()
-
-
Method Details
-
of
public static KeysetScrollDelegate of(org.springframework.data.domain.ScrollPosition.Direction direction) Factory method to obtain the rightKeysetScrollDelegate
.- Parameters:
direction
- the direction of scrolling.- Returns:
- a
KeysetScrollDelegate
matching the requested direction.
-
createPredicate
@Nullable public <E,P> P createPredicate(org.springframework.data.domain.KeysetScrollPosition keyset, org.springframework.data.domain.Sort sort, KeysetScrollDelegate.QueryStrategy<E, P> strategy) -
getSortOrders
protected org.springframework.data.domain.Sort getSortOrders(org.springframework.data.domain.Sort sort) -
postProcessResults
-
getResultWindow
-