|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.tapestry5.internal.grid.CollectionGridDataSource
public class CollectionGridDataSource
Constructor Summary | |
---|---|
CollectionGridDataSource(Collection collection)
|
Method Summary | |
---|---|
int |
getAvailableRows()
Returns the number of rows available in the data source. |
Class |
getRowType()
Returns the type of the first element in the list, or null if the list is empty. |
Object |
getRowValue(int index)
Returns the row value at the provided index. |
void |
prepare(int startIndex,
int endIndex,
List<SortConstraint> sortConstraints)
Invoked to allow the source to prepare to present values. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public CollectionGridDataSource(Collection collection)
Method Detail |
---|
public int getAvailableRows()
GridDataSource
getAvailableRows
in interface GridDataSource
public void prepare(int startIndex, int endIndex, List<SortConstraint> sortConstraints)
GridDataSource
prepare
in interface GridDataSource
startIndex
- the starting index to be retrievedendIndex
- the ending index to be retrievedsortConstraints
- identify how data is to be sortedpublic Class getRowType()
getRowType
in interface GridDataSource
public Object getRowValue(int index)
GridDataSource
GridDataSource.getAvailableRows()
may return a different number of rows than are actually available (i.e., the database
was changed between calls to GridDataSource.getAvailableRows()
and the call to GridDataSource.prepare(int, int,
java.util.List)
). In that case, this method should return null for any out-of-range indexes.
getRowValue
in interface GridDataSource
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |