|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.wicket.Component org.apache.wicket.MarkupContainer org.apache.wicket.markup.html.WebMarkupContainer org.apache.wicket.markup.repeater.AbstractRepeater org.apache.wicket.markup.html.list.ListView<T> org.apache.wicket.markup.html.list.PageableListView<T>
T
- Model object typepublic abstract class PageableListView<T>
PageableListView is similar to ListView but provides in addition pageable views. A PageableListView holds pageable rows of information. The rows can be re-ordered and deleted, either one at a time or many at a time.
Nested Class Summary |
---|
Nested classes/interfaces inherited from class org.apache.wicket.Component |
---|
Component.ComponentModelChange, Component.EnabledChange, Component.IVisitor<T extends Component>, Component.VisibilityChange |
Field Summary |
---|
Fields inherited from class org.apache.wicket.Component |
---|
ENABLE, FLAG_CONFIGURED, FLAG_INITIALIZED, FLAG_REMOVING_FROM_HIERARCHY, FLAG_RESERVED1, FLAG_RESERVED2, FLAG_RESERVED3, FLAG_RESERVED4, FLAG_RESERVED5, FLAG_RESERVED6, FLAG_RESERVED7, FLAG_RESERVED8, PARENT_PATH, PATH_SEPARATOR, RENDER |
Constructor Summary | |
---|---|
PageableListView(String id,
IModel<? extends List<? extends T>> model,
int rowsPerPage)
Constructor |
|
PageableListView(String id,
List<? extends T> list,
int rowsPerPage)
Creates a pageable list view having the given number of rows per page that uses the provided object as a simple model. |
Method Summary | |
---|---|
int |
getCurrentPage()
Gets the index of the current page being displayed by this list view. |
int |
getPageCount()
Gets the number of pages in this list view. |
int |
getRowsPerPage()
Gets the maximum number of rows on each page. |
int |
getViewSize()
Based on the model object's list size, firstIndex and view size, determine what the view size really will be. |
void |
setCurrentPage(int currentPage)
Sets the current page that this list view should show. |
void |
setRowsPerPage(int rowsPerPage)
Sets the maximum number of rows on each page. |
ListView<T> |
setStartIndex(int startIndex)
Prevent users from accidentally using it. |
ListView<T> |
setViewSize(int size)
Prevent users from accidentally using it. |
Methods inherited from class org.apache.wicket.markup.html.list.ListView |
---|
getList, getListItemModel, getModel, getModelObject, getReuseItems, getStartIndex, iterator, moveDownLink, moveUpLink, newItem, onBeginPopulateItem, onPopulate, populateItem, removeLink, renderChild, renderItem, renderIterator, setList, setModel, setModelObject, setReuseItems |
Methods inherited from class org.apache.wicket.markup.repeater.AbstractRepeater |
---|
onBeforeRender, onRender |
Methods inherited from class org.apache.wicket.markup.html.WebMarkupContainer |
---|
getMarkupType, getWebPage, getWebRequest |
Methods inherited from class org.apache.wicket.MarkupContainer |
---|
add, addOrReplace, autoAdd, autoAdd, contains, findMarkupStream, get, get, getAssociatedMarkupStream, getMarkupStream, hasAssociatedMarkup, internalAdd, isTransparentResolver, iterator, newMarkupResourceStream, onAfterRenderChildren, onComponentTagBody, remove, remove, removeAll, renderAll, renderAssociatedMarkup, renderComponentTagBody, renderNext, replace, setDefaultModel, setMarkupStream, size, swap, toString, toString, visitChildren, visitChildren |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public PageableListView(String id, IModel<? extends List<? extends T>> model, int rowsPerPage)
id
- See Componentmodel
- See ComponentrowsPerPage
- Number of rows to show on a pagepublic PageableListView(String id, List<? extends T> list, int rowsPerPage)
id
- See Componentlist
- See ComponentrowsPerPage
- Number of rows to show on a pageListView.ListView(String, List)
Method Detail |
---|
public final int getCurrentPage()
getCurrentPage
in interface IPageable
public final int getPageCount()
getPageCount
in interface IPageable
public final int getRowsPerPage()
public final void setRowsPerPage(int rowsPerPage)
rowsPerPage
- the maximum number of rows on each page.public int getViewSize()
ListView
getViewSize
in class ListView<T>
ListView.getViewSize()
public final void setCurrentPage(int currentPage)
setCurrentPage
in interface IPageable
currentPage
- The currentPage to set.public ListView<T> setStartIndex(int startIndex) throws UnsupportedOperationException
setStartIndex
in class ListView<T>
startIndex
- First index of model object's list to display
UnsupportedOperationException
- alwaysListView.setStartIndex(int)
public ListView<T> setViewSize(int size) throws UnsupportedOperationException
setViewSize
in class ListView<T>
size
- the view size
UnsupportedOperationException
- alwaysListView.setStartIndex(int)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |