R
- the type representing a row in the table modelC
- the type representing the column identifiers in the table modelT
- the type representing table columnspublic interface TableSortModel<R,C,T>
Modifier and Type | Interface and Description |
---|---|
static interface |
TableSortModel.SortingState
Specifies a sorting state for a column.
|
Modifier and Type | Method and Description |
---|---|
void |
addSortingStateChangedListener(EventListener listener) |
java.lang.Class |
getColumnClass(C columnIdentifier)
Returns the class of the column with the given identifier
|
java.util.List<T> |
getColumns() |
TableSortModel.SortingState |
getSortingState(C columnIdentifier) |
boolean |
isSortingEnabled() |
void |
setSortingDirective(C columnIdentifier,
SortingDirective directive,
boolean addColumnToSort) |
void |
sort(java.util.List<R> items)
Sorts the given list according to the sort configuration
|
void sort(java.util.List<R> items)
items
- the items to sortvoid setSortingDirective(C columnIdentifier, SortingDirective directive, boolean addColumnToSort)
columnIdentifier
- the identifier of the column to sort bydirective
- the sorting directiveaddColumnToSort
- if false then the sorting state is cleared, otherwise
this column is added to the sorted column set according to sorting prioritygetSortingState(Object)
TableSortModel.SortingState getSortingState(C columnIdentifier)
columnIdentifier
- the column identifierTableSortModel.SortingState
associated with the given columnboolean isSortingEnabled()
java.util.List<T> getColumns()
java.lang.Class getColumnClass(C columnIdentifier)
columnIdentifier
- the column identifiervoid addSortingStateChangedListener(EventListener listener)
listener
- a listener notified each time the sorting state changes