ViewVC Help
View File | Revision Log | Show Annotations | Download File | Root Listing
root/jsr166/jsr166/src/main/java/util/NavigableSet.java
(Generate patch)

Comparing jsr166/src/main/java/util/NavigableSet.java (file contents):
Revision 1.2 by dl, Tue Mar 8 12:27:06 2005 UTC vs.
Revision 1.3 by dl, Tue Mar 22 01:30:10 2005 UTC

# Line 46 | Line 46 | public interface NavigableSet<E> extends
46       * @throws NullPointerException if o is <tt>null</tt>
47       * and this set does not permit <tt>null</tt> elements
48       */
49 <    public E ceiling(E o);
49 >    E ceiling(E o);
50  
51      /**
52       * Returns an element strictly less than the given element, or
# Line 60 | Line 60 | public interface NavigableSet<E> extends
60       * @throws NullPointerException if o is <tt>null</tt>
61       * and this set does not permit <tt>null</tt> elements
62       */
63 <    public E lower(E o);
63 >    E lower(E o);
64  
65      /**
66       * Returns an element less than or equal to the given element, or
# Line 74 | Line 74 | public interface NavigableSet<E> extends
74       * @throws NullPointerException if o is <tt>null</tt>.
75       * and this set does not permit <tt>null</tt> elements
76       */
77 <    public E floor(E o);
77 >    E floor(E o);
78  
79      /**
80       * Returns an element strictly greater than the given element, or
# Line 88 | Line 88 | public interface NavigableSet<E> extends
88       * @throws NullPointerException if o is <tt>null</tt>
89       * and this set does not permit <tt>null</tt> elements
90       */
91 <    public E higher(E o);
91 >    E higher(E o);
92  
93      /**
94       * Retrieves and removes the first (lowest) element.
95       *
96       * @return the first element, or <tt>null</tt> if empty.
97       */
98 <    public E pollFirst();
98 >    E pollFirst();
99  
100      /**
101       * Retrieves and removes the last (highest) element.
102       *
103       * @return the last element, or <tt>null</tt> if empty.
104       */
105 <    public E pollLast();
105 >    E pollLast();
106  
107      /**
108       * Returns an iterator over the elements in this collection, in
# Line 113 | Line 113 | public interface NavigableSet<E> extends
113      Iterator<E> descendingIterator();
114  
115      /**
116 <     * Returns a view of the portion of this set whose elements range from
117 <     * <tt>fromElement</tt>, inclusive, to <tt>toElement</tt>, exclusive.  (If
118 <     * <tt>fromElement</tt> and <tt>toElement</tt> are equal, the returned
119 <     * sorted set is empty.)  The returned sorted set is backed by this set,
120 <     * so changes in the returned sorted set are reflected in this set, and
121 <     * vice-versa.
116 >     * Returns a view of the portion of this set whose elements range
117 >     * from <tt>fromElement</tt>, inclusive, to <tt>toElement</tt>,
118 >     * exclusive.  (If <tt>fromElement</tt> and <tt>toElement</tt> are
119 >     * equal, the returned navigable set is empty.)  The returned
120 >     * navigable set is backed by this set, so changes in the returned
121 >     * navigable set are reflected in this set, and vice-versa. Note:
122 >     * This method differs from <tt>SortedSet.subSet</tt> only in that
123 >     * the returned set is guaranteed to support the
124 >     * <tt>NavigableSet</tt> interface.
125 >     *
126       * @param fromElement low endpoint (inclusive) of the subSet.
127       * @param toElement high endpoint (exclusive) of the subSet.
128       * @return a view of the portion of this set whose elements range from
# Line 134 | Line 138 | public interface NavigableSet<E> extends
138       *         <tt>toElement</tt> is <tt>null</tt>
139       * and this set does not permit <tt>null</tt> elements
140       */
141 <    public NavigableSet<E> subSet(E fromElement, E toElement);
141 >    NavigableSet<E> navigableSubSet(E fromElement, E toElement);
142  
143      /**
144 <     * Returns a view of the portion of this set whose elements are strictly
145 <     * less than <tt>toElement</tt>.  The returned sorted set is backed by
146 <     * this set, so changes in the returned sorted set are reflected in this
147 <     * set, and vice-versa.  
144 >     * Returns a view of the portion of this set whose elements are
145 >     * strictly less than <tt>toElement</tt>.  The returned navigable
146 >     * set is backed by this set, so changes in the returned navigable
147 >     * set are reflected in this set, and vice-versa.
148       * @param toElement high endpoint (exclusive) of the headSet.
149       * @return a view of the portion of this set whose elements are strictly
150       *         less than toElement.
# Line 150 | Line 154 | public interface NavigableSet<E> extends
154       * @throws NullPointerException if <tt>toElement</tt> is <tt>null</tt>
155       * and this set does not permit <tt>null</tt> elements
156       */
157 <    public NavigableSet<E> headSet(E toElement);
157 >    NavigableSet<E> navigableHeadSet(E toElement);
158  
159      /**
160       * Returns a view of the portion of this set whose elements are
161       * greater than or equal to <tt>fromElement</tt>.  The returned
162 <     * sorted set is backed by this set, so changes in the returned
163 <     * sorted set are reflected in this set, and vice-versa.
162 >     * navigable set is backed by this set, so changes in the returned
163 >     * navigable set are reflected in this set, and vice-versa.
164       * @param fromElement low endpoint (inclusive) of the tailSet.
165       * @return a view of the portion of this set whose elements are
166       * greater than or equal to <tt>fromElement</tt>.
# Line 167 | Line 171 | public interface NavigableSet<E> extends
171       * @throws NullPointerException if <tt>fromElement</tt> is <tt>null</tt>
172       * and this set does not permit <tt>null</tt> elements
173       */
174 <    public NavigableSet<E> tailSet(E fromElement);
174 >    NavigableSet<E> navigableTailSet(E fromElement);
175   }

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines