public class BeanListPageElement<T> extends ListPageElement<T> implements ListItemSelection
Modifier and Type | Class and Description |
---|---|
static class |
BeanListPageElement.BeanListTableInfo
Extended ListTableInfo
|
ListPageElement.ListTableInfo, ListPageElement.SelectableItem, ListPageElement.SelectionSet
Modifier and Type | Field and Description |
---|---|
protected boolean |
defaultSortAscending |
protected Column |
defaultSortColumn |
static String |
IDPARAM_PROPERTY |
protected int |
maxItemCount |
static String |
NO_RESULT_ATTRIBUTE |
protected DBRowSet |
rowset |
protected DBOrderByExpr |
secondarySortOrder |
beanClass, items, selectedItems
Constructor and Description |
---|
BeanListPageElement(Page page,
Class<T> beanClass,
DBColumn defaultSortColumn,
String propertyName) |
Modifier and Type | Method and Description |
---|---|
void |
clearItems() |
protected void |
generateIdParams(DBRowSet rowset,
List<?> items) |
Column |
getDefaultSortColumn() |
int |
getItemCount()
returns the total item count of the entire list (not just the visible part)
|
protected Object[] |
getItemKey(DBColumn[] cols,
Object item) |
DBCommand |
getItemQueryCmd() |
protected ParameterMap |
getParameterMap() |
int |
getScrollbarPosition() |
DBOrderByExpr |
getSecondarySortOrder() |
Set<Object[]> |
getSelectedItemKeys() |
ListPageElement.ListTableInfo |
getTableInfo()
session scoped properties
|
void |
initItems(DBCommand queryCmd)
Init list items without pagination
|
void |
initItems(DBCommand queryCmd,
DBCommand countCmd,
int pageSize)
Init list items with pagination
|
void |
initItems(DBCommand queryCmd,
int pageSize)
Init list items without pagination
|
void |
initScrollbar()
addJavascriptCall to initScrollbar
|
boolean |
isDefaultSortAscending() |
boolean |
isResultEmpty()
Returns true if (and only if) items are valid but empty
|
protected void |
loadItems(boolean initScrollbar)
loads all visible list items from the database
|
protected void |
onInitPage() |
protected void |
onRefreshPage() |
void |
positionValueChanged(javax.faces.event.ValueChangeEvent ve) |
void |
setDefaultSortAscending(boolean defaultSortAscending) |
protected void |
setOrderBy(DBCommand cmd)
set order by for db queries
|
protected void |
setOrderBy(DBCommand cmd,
DBColumnExpr sortColumn,
boolean sortAscending) |
void |
setScrollbarPosition(int value) |
void |
setSecondarySortOrder(DBOrderByExpr secondarySortOrder) |
void |
setSelectedItems(Set<Object[]> items) |
void |
updateScrollbar()
addJavascriptCall to updateScrollbar
|
assignSelectionMap, clearSelection, getItems, getSelectedItemCount, getSelectedItems, isBlank, isEmpty, isHasSelection, isInvertSelection, isNotEmpty, isSingleSelection, isValid, setInvertSelection, setSelection, setSelection, setSingleSelection
getConnection, getConnection, getPage, getPropertyName, getSessionObject, removeSessionObject, setSessionObject
public static final String IDPARAM_PROPERTY
public static final String NO_RESULT_ATTRIBUTE
protected DBRowSet rowset
protected Column defaultSortColumn
protected boolean defaultSortAscending
protected DBOrderByExpr secondarySortOrder
protected int maxItemCount
protected void onInitPage()
onInitPage
in class PageElement
protected void onRefreshPage()
onRefreshPage
in class PageElement
public int getItemCount()
ListPageElement
getItemCount
in class ListPageElement<T>
public Column getDefaultSortColumn()
public boolean isDefaultSortAscending()
public void setDefaultSortAscending(boolean defaultSortAscending)
public DBOrderByExpr getSecondarySortOrder()
public void setSecondarySortOrder(DBOrderByExpr secondarySortOrder)
public ListPageElement.ListTableInfo getTableInfo()
getTableInfo
in class ListPageElement<T>
public void clearItems()
clearItems
in class ListPageElement<T>
protected ParameterMap getParameterMap()
public void initItems(DBCommand queryCmd, DBCommand countCmd, int pageSize)
queryCmd
- pageSize
- public final void initItems(DBCommand queryCmd, int pageSize)
queryCmd
- public final void initItems(DBCommand queryCmd)
queryCmd
- public boolean isResultEmpty()
protected void loadItems(boolean initScrollbar)
initScrollbar
- protected void setOrderBy(DBCommand cmd)
cmd
- protected void setOrderBy(DBCommand cmd, DBColumnExpr sortColumn, boolean sortAscending)
public void initScrollbar()
public void updateScrollbar()
public int getScrollbarPosition()
public void setScrollbarPosition(int value)
public void positionValueChanged(javax.faces.event.ValueChangeEvent ve)
public DBCommand getItemQueryCmd()
getItemQueryCmd
in interface ListItemSelection
Copyright © 2008–2015 Apache Software Foundation. All rights reserved.