13 |
|
* <tt>floor</tt>, <tt>ceiling</tt>, and <tt>higher</tt> return keys |
14 |
|
* respectively less than, less than or equal, greater than or equal, |
15 |
|
* and greater than a given key, returning <tt>null</tt> if there is |
16 |
< |
* no such key. These methods are designed for locating, not |
17 |
< |
* traversing entries. To traverse, use view iterators and/or |
18 |
< |
* <tt>subset</tt>. This interface additionally defines methods |
19 |
< |
* <tt>pollFirst</tt> and <t>pollLast</tt> that return and remove the |
20 |
< |
* lowest and highest key, if one exists, else returning |
21 |
< |
* <tt>null</tt>. |
16 |
> |
* no such key. A <tt>NavigableSet</tt> may be viewed and traversed |
17 |
> |
* in either ascending or descending order. The <tt>Collection</tt> |
18 |
> |
* <tt>iterator</tt> method returns an ascending <tt>Iterator</tt> and |
19 |
> |
* the additional method <tt>descendingIterator</tt> returns |
20 |
> |
* descending iterator. The performance of ascending traversals is |
21 |
> |
* likely to be faster than descending traversals. This interface |
22 |
> |
* additionally defines methods <tt>pollFirst</tt> and |
23 |
> |
* <t>pollLast</tt> that return and remove the lowest and highest key, |
24 |
> |
* if one exists, else returning <tt>null</tt>. |
25 |
|
* |
26 |
< |
* <p> The return values of these methods may be ambiguous in |
26 |
> |
* <p> The return values of navigation methods may be ambiguous in |
27 |
|
* implementations that permit <tt>null</tt> elements. However, even |
28 |
|
* in this case the result can be disambiguated by checking |
29 |
|
* <tt>contains(null)</tt>. To avoid such issues, implementations of |
106 |
|
public E pollLast(); |
107 |
|
|
108 |
|
/** |
109 |
+ |
* Returns an iterator over the elements in this collection, in |
110 |
+ |
* descending order. |
111 |
+ |
* |
112 |
+ |
* @return an <tt>Iterator</tt> over the elements in this collection |
113 |
+ |
*/ |
114 |
+ |
Iterator<E> descendingIterator(); |
115 |
+ |
|
116 |
+ |
/** |
117 |
|
* Returns a view of the portion of this set whose elements range from |
118 |
|
* <tt>fromElement</tt>, inclusive, to <tt>toElement</tt>, exclusive. (If |
119 |
|
* <tt>fromElement</tt> and <tt>toElement</tt> are equal, the returned |