Interface Pagination<T>
- Type Parameters:
 T- a domain type like User
@Immutable
public interface Pagination<T>
A container for a partial list of objects, that are being returned paginated.
 Has the pagination information needed to get the rest of the objects
- 
Method Summary
Modifier and TypeMethodDescriptiongetList()Will be null once we have read the last page availableintgetPage()intintstatic <T> Pagination<T>of(PaginatedList paginatedList, List<T> elements)  
- 
Method Details
- 
getList
 - 
getPerPage
int getPerPage() - 
getTotalPages
int getTotalPages() - 
getNextPage
Will be null once we have read the last page available- Returns:
 - either the number of the next page or null if the list has ended
 
 - 
getPreviousPage
 - 
getPage
int getPage() - 
of
 
 -