RowSorterEvent provides notification of changes to
a RowSorter. Two types of notification are possible:
Type.SORT_ORDER_CHANGED: indicates the sort order has
changed. This is typically followed by a notification of:
Type.SORTED: indicates the contents of the model have
been transformed in some way. For example, the contents may have
been sorted or filtered.
javax.swing.RowSorter
| Modifier and Type | Class and Description |
|---|---|
| public static enum | RowSorterEvent.
Enumeration of the types of |
| Modifier and Type | Field and Description |
|---|---|
| private int[] | |
| private RowSorterEvent. |
| Access | Constructor and Description |
|---|---|
| public | RowSorterEvent(RowSorter<?>
the source of the change source)Creates a |
| public | RowSorterEvent(RowSorter<?>
the source of the change source, RowSorterEvent.the type of event type,the mapping from model indices to
view indices prior to the sort, may be previousRowIndexToModel)nullCreates a |
| Modifier and Type | Method and Description |
|---|---|
| public int | Returns: the index in terms of the model prior to the sort, or -1 if the location is not valid or the mapping was not provided.the index in terms of the view index)Returns the location of |
| public int | Returns: the number of rows in terms of the view prior to the sortReturns the number of rows before the sort. |
| public RowSorter | Returns: the source of the event as aRowSorterOverrides java. Returns the source of the event as a |
| public RowSorterEvent. |
| oldViewToModel | back to summary |
|---|---|
| private int[] oldViewToModel | |
| type | back to summary |
|---|---|
| private RowSorterEvent. | |
| RowSorterEvent | back to summary |
|---|---|
| public RowSorterEvent(RowSorter<?> source) Creates a
| |
| RowSorterEvent | back to summary |
|---|---|
| public RowSorterEvent(RowSorter<?> source, RowSorterEvent. Creates a
| |
| convertPreviousRowIndexToModel | back to summary |
|---|---|
| public int convertPreviousRowIndexToModel(int index) Returns the location of
| |
| getPreviousRowCount | back to summary |
|---|---|
| public int getPreviousRowCount() Returns the number of rows before the sort. This method is only
useful for events of type
| |
| getSource | back to summary |
|---|---|
| public RowSorter Overrides java. Returns the source of the event as a | |
| getType | back to summary |
|---|---|
| public RowSorterEvent. Returns the type of event.
| |
RowSorterEvents.
| Modifier and Type | Field and Description |
|---|---|
| public static final RowSorterEvent. | SORT_ORDER_CHANGED
Indicates the sort order has changed. |
| public static final RowSorterEvent. | SORTED
Indicates the contents have been newly sorted or transformed in some way. |
| Access | Constructor and Description |
|---|---|
| private |
| Modifier and Type | Method and Description |
|---|---|
| public static RowSorterEvent. | |
| public static RowSorterEvent. |
| SORT_ORDER_CHANGED | back to summary |
|---|---|
| public static final RowSorterEvent. Indicates the sort order has changed. | |
| SORTED | back to summary |
|---|---|
| public static final RowSorterEvent. Indicates the contents have been newly sorted or transformed in some way. | |
| Type | back to summary |
|---|---|
| private Type() | |
| valueOf | back to summary |
|---|---|
| public static RowSorterEvent. | |
| values | back to summary |
|---|---|
| public static RowSorterEvent. | |