Interface PaginationServiceInternal
-
- All Superinterfaces:
PaginationService
- All Known Implementing Classes:
PaginationServiceImpl
public interface PaginationServiceInternal extends PaginationService
Additional pagination functionality dealing with PagingIterators / Paginated live here Until CONFDEV-26743 is resolved and we have a blessed path going forward, the PagingIterator / Paginated types should not be leaked to consumers.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Deprecated Methods Modifier and Type Method Description <F,T>
Paginated<T>createPaginated(PaginationBatch<F> fetchBatch, com.google.common.base.Function<Iterable<F>,Iterable<T>> modelConverter, int maxLimit)
Deprecated.since 7.0.1.<F,T>
PagingIterator<T>createPagingIterator(PaginationBatch<F> fetchBatch, int resultsPerPage, com.google.common.base.Function<Iterable<F>,Iterable<T>> modelConverter)
Deprecated.since 7.0.1.default <F,T>
Paginated<T>newPaginated(PaginationBatch<F> fetchBatch, Function<Iterable<F>,Iterable<T>> modelConverter, int maxLimit)
Constructs a Paginated implementation backed by the given PaginationBatch.default <F,T>
PagingIterator<T>newPagingIterator(PaginationBatch<F> fetchBatch, int resultsPerPage, Function<Iterable<F>,Iterable<T>> modelConverter)
Constructs a PagingIterator backed by the given PaginationBatch.-
Methods inherited from interface com.atlassian.confluence.api.service.pagination.PaginationService
doPaginationListRequest, doPaginationRequest, performPaginationListRequest, performPaginationListRequestWithCursor, performPaginationRequest
-
-
-
-
Method Detail
-
createPagingIterator
@Deprecated <F,T> PagingIterator<T> createPagingIterator(PaginationBatch<F> fetchBatch, int resultsPerPage, com.google.common.base.Function<Iterable<F>,Iterable<T>> modelConverter)
Deprecated.since 7.0.1. UsenewPagingIterator(PaginationBatch, int, Function)
Constructs a PagingIterator backed by the given PaginationBatch. The Iterator is guaranteed to yield all results provided by the PaginationBatch. No more than resultsPerPage are fetched from the PaginationBatch at one time, and each batch of data is only kept live for the time it takes callers to iterate through it.- Parameters:
fetchBatch
- - a request for a range of dataresultsPerPage
- - number of results to request from PaginationBatch each invocation.modelConverter
- - a function to convert from the supplied object to a model object, this will be executed within a transaction.- Returns:
- a PagingIterator of model objects, with results that the user is allowed to see.
- See Also:
PagingIterator
-
newPagingIterator
default <F,T> PagingIterator<T> newPagingIterator(PaginationBatch<F> fetchBatch, int resultsPerPage, Function<Iterable<F>,Iterable<T>> modelConverter)
Constructs a PagingIterator backed by the given PaginationBatch. The Iterator is guaranteed to yield all results provided by the PaginationBatch. No more than resultsPerPage are fetched from the PaginationBatch at one time, and each batch of data is only kept live for the time it takes callers to iterate through it.- Parameters:
fetchBatch
- - a request for a range of dataresultsPerPage
- - number of results to request from PaginationBatch each invocation.modelConverter
- - a function to convert from the supplied object to a model object, this will be executed within a transaction.- Returns:
- a PagingIterator of model objects, with results that the user is allowed to see.
- Since:
- 7.0.1
- See Also:
PagingIterator
-
createPaginated
@Deprecated <F,T> Paginated<T> createPaginated(PaginationBatch<F> fetchBatch, com.google.common.base.Function<Iterable<F>,Iterable<T>> modelConverter, int maxLimit)
Deprecated.since 7.0.1. UsenewPaginated(PaginationBatch, Function, int)
Constructs a Paginated implementation backed by the given PaginationBatch.- Parameters:
fetchBatch
- - a request for a range of datamodelConverter
- - a function to convert from the supplied object to a model object, this will be executed within a transaction.maxLimit
- - the max limit to apply when creating LimitedRequests for paged requests from the Paginated.- See Also:
Paginated
-
newPaginated
default <F,T> Paginated<T> newPaginated(PaginationBatch<F> fetchBatch, Function<Iterable<F>,Iterable<T>> modelConverter, int maxLimit)
Constructs a Paginated implementation backed by the given PaginationBatch.- Parameters:
fetchBatch
- - a request for a range of datamodelConverter
- - a function to convert from the supplied object to a model object, this will be executed within a transaction.maxLimit
- - the max limit to apply when creating LimitedRequests for paged requests from the Paginated.- Since:
- 7.0.1
- See Also:
Paginated
-
-