Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

com.ibatis.common.util
Interface PaginatedList  view PaginatedList download PaginatedList.java

All Superinterfaces:
java.util.Collection, java.lang.Iterable, java.util.List
All Known Implementing Classes:
PaginatedArrayList

public interface PaginatedList
extends java.util.List

Interface for lists that support paging


Method Summary
 int getPageIndex()
          Returns the current page index, which is a zero based integer.
 int getPageSize()
          Returns the maximum number of items per page
 void gotoPage(int pageNumber)
          Moves to a specified page.
 boolean isFirstPage()
          Is the current page the first page?
 boolean isLastPage()
          Is the current page the last page?
 boolean isMiddlePage()
          Is the current page a middle page (i.e.
 boolean isNextPageAvailable()
          Is a page available after the current page?
 boolean isPreviousPageAvailable()
          Is a page available before the current page?
 boolean nextPage()
          Moves to the next page after the current page.
 boolean previousPage()
          Moves to the page before the current page.
 
Methods inherited from interface java.util.List
add, add, addAll, addAll, clear, contains, containsAll, equals, get, hashCode, indexOf, isEmpty, iterator, lastIndexOf, listIterator, listIterator, remove, remove, removeAll, retainAll, set, size, subList, toArray, toArray
 

Method Detail

getPageSize

public int getPageSize()
Returns the maximum number of items per page


isFirstPage

public boolean isFirstPage()
Is the current page the first page?


isMiddlePage

public boolean isMiddlePage()
Is the current page a middle page (i.e. not first or last)?


isLastPage

public boolean isLastPage()
Is the current page the last page?


isNextPageAvailable

public boolean isNextPageAvailable()
Is a page available after the current page?


isPreviousPageAvailable

public boolean isPreviousPageAvailable()
Is a page available before the current page?


nextPage

public boolean nextPage()
Moves to the next page after the current page. If the current page is the last page, wrap to the first page.


previousPage

public boolean previousPage()
Moves to the page before the current page. If the current page is the first page, wrap to the last page.


gotoPage

public void gotoPage(int pageNumber)
Moves to a specified page. If the specified page is beyond the last page, wrap to the first page. If the specified page is before the first page, wrap to the last page.


getPageIndex

public int getPageIndex()
Returns the current page index, which is a zero based integer. All paginated list implementations should know what index they are on, even if they don't know the ultimate boundaries (min/max).