Package org.alfresco.repo.virtual.page
Class PageCollator<R>
java.lang.Object
org.alfresco.repo.virtual.page.PageCollator<R>
- Type Parameters:
R-
A generic utility for arranging a
List of objects of type
R into a R objects page obtained from a
PageCollator.PagingResultsSource considering a given PagingRequest for the
resulted PagingResults.- Author:
- Bogdan Horje
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic interfaceImplementors are paging request capable objects - i.e. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionorg.alfresco.query.PagingResults<R>collate(List<R> objects, PageCollator.PagingResultsSource<R> objectPageSurce, org.alfresco.query.PagingRequest pagingRequest, Comparator<R> comparator)
-
Constructor Details
-
PageCollator
public PageCollator()
-
-
Method Details
-
collate
public org.alfresco.query.PagingResults<R> collate(List<R> objects, PageCollator.PagingResultsSource<R> objectPageSurce, org.alfresco.query.PagingRequest pagingRequest, Comparator<R> comparator) throws PageCollationException - Parameters:
objects-objectPageSurce-pagingRequest-comparator-- Returns:
- a
PagingResultsR objects obtained from merging a collection of R objects with a paged result obtained from aPageCollator.PagingResultsSourceconsidering the a merged resultPagingRequest - Throws:
PageCollationException
-