public abstract class TreeModelDecorator extends TreeModel
LocalRowKeyIndex.Confidence, LocalRowKeyIndex.LocalCachingStrategyUNKNOWN_ROW_LIMIT, UNLIMITED_ROW| Constructor and Description |
|---|
TreeModelDecorator() |
| Modifier and Type | Method and Description |
|---|---|
void |
enterContainer()
This Collection changes to reflect the children of the current rowData,
and the current rowData changes to be null.
|
void |
exitContainer()
Pops back up to the parent collection.
|
Object |
getContainerRowKey(Object childRowKey)
Gets the rowKey of a given child row's container row.
|
int |
getRowCount()
Gets the number of values in this collection
|
Object |
getRowData()
Gets the current value identified by the current index or rowKey.
|
int |
getRowIndex()
Gets the index of the current value.
|
Object |
getRowKey()
Gets the rowKey of the current row.
|
protected abstract TreeModel |
getTreeModel()
This method returns the wrapped
TreeModel. |
Object |
getWrappedData() |
boolean |
isContainer()
Tests to see if the row identified by getRowData() is a container element.
|
boolean |
isRowAvailable()
Checks to make sure a value exists for the current index or rowKey.
|
void |
setRowIndex(int i)
Sets up a value at a particular index to be the current value.
|
void |
setRowKey(Object key)
Finds the row with the matching key and makes it current
|
void |
setWrappedData(Object object) |
areRowsLocallyAvailable, areRowsLocallyAvailable, areRowsLocallyAvailable, getAllAncestorContainerRowKeys, getContainerRowKey, getDepth, getDepth, isChildCollectionLocallyAvailable, isChildCollectionLocallyAvailable, isChildCollectionLocallyAvailable, isContainerEmptyaddRowKeyChangeListener, areRowsAvailable, areRowsAvailable, areRowsAvailable, areRowsLocallyAvailable, areRowsLocallyAvailable, areRowsLocallyAvailable, clearCachedRow, clearCachedRow, clearCachedRows, clearCachedRows, clearLocalCache, ensureRowsAvailable, fireRowKeyChange, getCachingStrategy, getEstimatedRowCount, getEstimatedRowCountConfidence, getRowData, getRowData, getRowLimit, getSortCriteria, isRowAvailable, isRowAvailable, isRowLocallyAvailable, isRowLocallyAvailable, isSortable, removeRowKeyChangeListener, setSortCriteriapublic void enterContainer()
TreeModelTreeModel.isContainer() returns true.
DataModel.getRowCount() can be used to get the number of children.enterContainer in class TreeModelpublic void exitContainer()
TreeModelexitContainer in class TreeModelpublic Object getContainerRowKey(Object childRowKey)
TreeModel|-Root1 (rowKey="r1", containerRowKey=null) | |-Folder1 (rowKey="r1f1", containerRowKey="r1") | | |-Node1 (rowKey="r1f1n1", containerRowKey="r1f1") | | |-Node2 (rowKey="r1f1n2", containerRowKey="r1f1")
getContainerRowKey in class TreeModelchildRowKey - the rowKey of the child row.public boolean isContainer()
TreeModelTreeModel.isContainerEmpty() to see if the current container element actually
has children, or is an empty container.isContainer in class TreeModelpublic Object getRowKey()
CollectionModelObject.equals(java.lang.Object) and Object.hashCode() as they will be used
as keys in hashtables. rowKeys should also be Serializable, so that the
application can run under all JSF state-saving schemes.getRowKey in interface RowKeyIndexgetRowKey in class CollectionModelCollectionModel.setRowKey(java.lang.Object)public void setRowKey(Object key)
CollectionModelsetRowKey in interface RowKeyIndexsetRowKey in class CollectionModelkey - the rowKey, previously obtained from CollectionModel.getRowKey().public int getRowCount()
RowKeyIndexgetRowCount in interface RowKeyIndexgetRowCount in class javax.faces.model.DataModelpublic Object getRowData()
RowKeyIndexgetRowData in interface RowKeyIndexgetRowData in class javax.faces.model.DataModelRowKeyIndex.getRowKey(),
RowKeyIndex.getRowIndex()public int getRowIndex()
RowKeyIndexgetRowIndex in interface RowKeyIndexgetRowIndex in class javax.faces.model.DataModelpublic Object getWrappedData()
getWrappedData in class javax.faces.model.DataModelpublic boolean isRowAvailable()
RowKeyIndexRowKeyIndex.getRowCount()).isRowAvailable in interface RowKeyIndexisRowAvailable in class javax.faces.model.DataModelRowKeyIndex.getRowKey(),
RowKeyIndex.getRowIndex()public void setRowIndex(int i)
RowKeyIndexsetRowIndex in interface RowKeyIndexsetRowIndex in class javax.faces.model.DataModeli - the zero-based index of the value to make current.
Use -1 to clear the current valuepublic void setWrappedData(Object object)
setWrappedData in class javax.faces.model.DataModelprotected abstract TreeModel getTreeModel()
TreeModel.Copyright © 2001-2017 The Apache Software Foundation. All Rights Reserved.