When an {@link Ordered} or {@link Indexed} container is sorted, allrelevant operations of these interfaces should only use the filtered and sorted contents and the filtered indices to the container. Indices or item identifiers in the public API refer to the visible view unless otherwise stated. However, the addItem*()
methods may add items that will be filtered out after addition or moved to another position based on sorting.
How sorting is performed when a {@link Hierarchical} container implements{@link Sortable} is implementation specific and should be documented inthe implementing class. However, the recommended approach is sorting the roots and the sets of children of each item separately.
Depending on the container type, sorting a container may permanently change the internal order of items in the container.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|