R
- the type representing the rows in this table modelC
- type type used to identify columns in this table model, Integer for simple indexed identification for exampleT
- the type representing table columnspublic interface FilteredTableModel<R,C,T> extends FilteredModel<R>, Refreshable
Modifier and Type | Method and Description |
---|---|
void |
addRefreshDoneListener(EventListener listener) |
void |
addRefreshStartedListener(EventListener listener) |
void |
addRowsDeletedListener(EventDataListener<java.util.List<java.lang.Integer>> listener)
Adds a listener that is notified each time rows are deleted from the data model.
|
void |
addSortingListener(EventListener listener) |
void |
addTableDataChangedListener(EventListener listener) |
void |
addTableModelClearedListener(EventListener listener) |
boolean |
allowSelectionChange() |
RowColumn |
findNextItemCoordinate(int fromIndex,
boolean forward,
FilterCondition<java.lang.Object> condition)
Returns a RowColumn denoting the row and column index of the first value to fulfill
the given search condition.
|
RowColumn |
findNextItemCoordinate(int fromIndex,
boolean forward,
java.lang.String searchText)
Returns a RowColumn denoting the row and column index of the first value to fulfill
the given search condition.
|
FilteredTableColumnModel<C,T> |
getColumnModel() |
ColumnSummaryModel |
getColumnSummaryModel(C columnIdentifier) |
R |
getItemAt(int index) |
int |
getRowCount() |
SelectionModel<R> |
getSelectionModel() |
TableSortModel<R,C,T> |
getSortModel() |
java.util.Collection |
getValues(C columnIdentifier,
boolean selectedOnly) |
int |
indexOf(R item) |
boolean |
isRegularExpressionSearch() |
void |
removeItem(R item)
Removes the given item from this table model
|
void |
removeItems(java.util.Collection<R> items)
Removes the given items from this table model
|
void |
removeItems(int fromIndex,
int toIndex)
Removes from this table model all visible elements whose index is between fromIndex, inclusive and toIndex, exclusive
|
void |
removeRefreshDoneListener(EventListener listener) |
void |
removeRefreshStartedListener(EventListener listener) |
void |
removeRowsDeletedListener(EventDataListener listener) |
void |
removeSortingListener(EventListener listener) |
void |
removeTableDataChangedListener(EventListener listener) |
void |
removeTableModelClearedListener(EventListener listener) |
void |
setRegularExpressionSearch(boolean value)
Specifies whether or not to use regular expressions when searching this table model
|
void |
sortContents()
Sorts the visible contents according to the
TableSortModel , keeping the selection state intact |
addFilteringListener, contains, filterContents, getAllItems, getFilterCondition, getFilteredItemCount, getFilteredItems, getVisibleItemCount, getVisibleItems, isFiltered, isVisible, removeFilteringListener, setFilterCondition
clear, refresh
void addRefreshStartedListener(EventListener listener)
listener
- a listener to be notified each time a refresh is about to startvoid removeRefreshStartedListener(EventListener listener)
listener
- the listener to removevoid addRefreshDoneListener(EventListener listener)
listener
- a listener to be notified each time a refresh has endedvoid removeRefreshDoneListener(EventListener listener)
listener
- the listener to removevoid addSortingListener(EventListener listener)
listener
- a listener to be notified each time the model has been sorted or the sorting state has been clearedvoid removeSortingListener(EventListener listener)
listener
- the listener to removevoid addTableDataChangedListener(EventListener listener)
listener
- a listener to be notified each time the table data changesvoid removeTableDataChangedListener(EventListener listener)
listener
- the listener to removevoid addTableModelClearedListener(EventListener listener)
listener
- a listener to be notified each time the table model is clearedvoid removeTableModelClearedListener(EventListener listener)
listener
- the listener to removevoid addRowsDeletedListener(EventDataListener<java.util.List<java.lang.Integer>> listener)
listener
- the listener, the data list contains the fromIndex and toIndex as items at index 0 and 1void removeRowsDeletedListener(EventDataListener listener)
listener
- the listener to removeboolean allowSelectionChange()
int getRowCount()
int indexOf(R item)
item
- the itemR getItemAt(int index)
index
- the indexvoid removeItems(java.util.Collection<R> items)
items
- the items to remove from the modelvoid removeItem(R item)
item
- the item to remove from the modelvoid removeItems(int fromIndex, int toIndex)
fromIndex
- index of first row to be removedtoIndex
- index after last row to be removedjava.lang.IndexOutOfBoundsException
- in case the indexes are out of boundsFilteredTableColumnModel<C,T> getColumnModel()
ColumnSummaryModel getColumnSummaryModel(C columnIdentifier)
columnIdentifier
- the column identifierjava.util.Collection getValues(C columnIdentifier, boolean selectedOnly)
columnIdentifier
- the identifier of the column for which to retrieve the valuesselectedOnly
- if true only values from the selected rows are returnedcolumnIdentifier
from the rows in the table modelRowColumn findNextItemCoordinate(int fromIndex, boolean forward, java.lang.String searchText)
fromIndex
- the row index to start searching at, if this is larger than the size of
the table model or less than 0 the search starts from either 0 or rowCount - 1 depending on search direction.forward
- if true then the search is forward (towards higher row indexes), backwards otherwisesearchText
- the text to search byisRegularExpressionSearch()
,
FilterCondition.include(Object)
RowColumn findNextItemCoordinate(int fromIndex, boolean forward, FilterCondition<java.lang.Object> condition)
fromIndex
- the row index to start searching at, if this is larger than the size of
the table model or less than 0 the search starts from either 0 or rowCount - 1 depending on search direction.forward
- if true then the search is forward (towards higher row indexes), backwards otherwisecondition
- the search conditionFilterCondition.include(Object)
boolean isRegularExpressionSearch()
void setRegularExpressionSearch(boolean value)
value
- the valuevoid sortContents()
TableSortModel
, keeping the selection state intactgetSortModel()
SelectionModel<R> getSelectionModel()
TableSortModel<R,C,T> getSortModel()