mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-28 15:24:43 +02:00
8266571: Sequenced Collections
Reviewed-by: alanb
This commit is contained in:
parent
bad6aa68e4
commit
17ce0976e4
42 changed files with 7060 additions and 150 deletions
|
@ -429,4 +429,20 @@ public interface NavigableMap<K,V> extends SortedMap<K,V> {
|
|||
* @throws IllegalArgumentException {@inheritDoc}
|
||||
*/
|
||||
SortedMap<K,V> tailMap(K fromKey);
|
||||
|
||||
/**
|
||||
* {@inheritDoc}
|
||||
* <p>
|
||||
* This method is equivalent to {@link #descendingMap descendingMap}.
|
||||
*
|
||||
* @implSpec
|
||||
* The implementation in this interface returns the result of calling the
|
||||
* {@code descendingMap} method.
|
||||
*
|
||||
* @return a reverse-ordered view of this map, as a {@code NavigableMap}
|
||||
* @since 21
|
||||
*/
|
||||
default NavigableMap<K, V> reversed() {
|
||||
return this.descendingMap();
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue