I followed the Spring Data release notes and try the new Scroll APIs, but found the methods mentioned in the doc used package scope.
I think these method should be public.
/**
* Creates a new initial {@link OffsetScrollPosition} to start scrolling using offset/limit.
*
* @return will never be {@literal null}.
*/
static OffsetScrollPosition initial() {
return INITIAL;
}
/**
* Creates a new {@link OffsetScrollPosition} from an {@code offset}.
*
* @param offset the non-negative offset to start at.
* @return will never be {@literal null}.
*/
static OffsetScrollPosition of(long offset) {
return offset == 0 ? initial() : new OffsetScrollPosition(offset);
}