public interface HasRows<T> extends com.google.gwt.event.shared.HasHandlers
Modifier and Type | Method and Description |
---|---|
void |
clearRows(boolean clearData)
Clear data rows.
|
void |
deselectRow(com.google.gwt.dom.client.Element row,
boolean fireEvent)
Unselect a selected row.
|
RowComponent<T> |
getRow(int index)
Get a row by its rendered index.
|
RowComponent<T> |
getRow(T model)
Get a row by its representing model.
|
RowComponent<T> |
getRowByModel(T model)
Get a models
RowComponent or null if not found. |
int |
getRowCount()
Get the exact count of all rows.
|
RowComponentFactory<T> |
getRowFactory()
Get the views row factory.
|
int |
getRowHeight()
Get the maximum row height.
|
List<RowComponent<T>> |
getRows()
Get all data views
RowComponent 's. |
List<T> |
getSelectedRowModels(boolean visibleOnly)
Get all the selected row models.
|
SelectionType |
getSelectionType()
Get the data views row selection type.
|
int |
getTotalRows()
Get the configured total rows count.
|
com.google.gwt.view.client.Range |
getVisibleRange()
Get the range of visible rows.
|
boolean |
hasDeselectedRows(boolean visibleOnly)
Does this view have unselected rows.
|
boolean |
hasSelectedRows(boolean visibleOnly)
Does this view have selected rows.
|
void |
selectAllRows(boolean select)
Select or deselect all rows.
|
void |
selectAllRows(boolean select,
boolean fireEvent)
Select or deselect all rows.
|
void |
selectRow(com.google.gwt.dom.client.Element row,
boolean fireEvent)
Select a given row.
|
void |
setRowData(int start,
List<? extends T> values)
Set values associated with the rows in the visible range.
|
void |
setRowFactory(RowComponentFactory<T> rowFactory)
Set your own custom
RowComponentFactory to generate your row components. |
void |
setRowHeight(int rowHeight)
Set maximum row height.
|
void |
setSelectionType(SelectionType selectionType)
Set the data views row selection type.
|
void |
setTotalRows(int totalRows)
Set the total row count.
|
void |
setVisibleRange(int start,
int length)
Set the visible range or rows.
|
void |
setVisibleRange(com.google.gwt.view.client.Range range)
Set the visible range or rows.
|
void |
updateRow(T model)
Update a models row within the table.
|
com.google.gwt.view.client.Range getVisibleRange()
setVisibleRange(Range)
,
setVisibleRange(int, int)
void setVisibleRange(int start, int length)
setVisibleRange(Range)
.start
- the start indexlength
- the lengthgetVisibleRange()
void setVisibleRange(com.google.gwt.view.client.Range range)
range
- the visible rangegetVisibleRange()
int getRowCount()
int getTotalRows()
void setTotalRows(int totalRows)
void setRowData(int start, List<? extends T> values)
start
- the start index of the datavalues
- the values within the rangeint getRowHeight()
void setRowHeight(int rowHeight)
void updateRow(T model)
model
- a model with a valid equals
method.List<RowComponent<T>> getRows()
RowComponent
's.RowComponent<T> getRow(T model)
model
- the model assigned to a row.RowComponent<T> getRow(int index)
index
- the value of the render index.RowComponent<T> getRowByModel(T model)
RowComponent
or null if not found.model
- a model with a valid equals
method.RowComponent
.void clearRows(boolean clearData)
clearData
- should we also clear the stored data.void setRowFactory(RowComponentFactory<T> rowFactory)
RowComponentFactory
to generate your row components.RowComponentFactory<T> getRowFactory()
void setSelectionType(SelectionType selectionType)
SelectionType getSelectionType()
void selectAllRows(boolean select)
select
- true will select, false with deselectvoid selectAllRows(boolean select, boolean fireEvent)
select
- true will select, false with deselectfireEvent
- fire the '' event.void selectRow(com.google.gwt.dom.client.Element row, boolean fireEvent)
void deselectRow(com.google.gwt.dom.client.Element row, boolean fireEvent)
boolean hasDeselectedRows(boolean visibleOnly)
visibleOnly
- should we restrict this check to visible rows only.boolean hasSelectedRows(boolean visibleOnly)
visibleOnly
- should we restrict this check to visible rows only.List<T> getSelectedRowModels(boolean visibleOnly)
visibleOnly
- should we restrict this check to visible rows only.Copyright © 2018. All rights reserved.