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

Comparing jsr166/src/main/java/util/concurrent/ConcurrentSkipListSet.java (file contents):
Revision 1.13 by dl, Thu May 26 12:07:14 2005 UTC vs.
Revision 1.14 by jsr166, Sun Jun 19 23:01:12 2005 UTC

# Line 165 | Line 165 | public class ConcurrentSkipListSet<E>
165  
166      /**
167       * Returns <tt>true</tt> if this set contains the specified element.
168 +     * More formally, returns <tt>true</tt> if and only if this set
169 +     * contains an element <tt>e</tt> such that <tt>o.equals(e)</tt>.
170       *
171 <     * @param o the object to be checked for containment in this set
171 >     * @param o object to be checked for containment in this set
172       * @return <tt>true</tt> if this set contains the specified element
173       * @throws ClassCastException if the specified element cannot be
174 <     *         compared with the elements currently in the set
174 >     *         compared with the elements currently in this set
175       * @throws NullPointerException if the specified element is null
176       */
177      public boolean contains(Object o) {
# Line 178 | Line 180 | public class ConcurrentSkipListSet<E>
180  
181      /**
182       * Adds the specified element to this set if it is not already present.
183 +     * More formally, adds the specified element <tt>e</tt> to this set if
184 +     * the set contains no element <tt>e2</tt> such that <tt>e.equals(e2)</tt>.
185 +     * If this set already contains the element, the call leaves the set
186 +     * unchanged and returns <tt>false</tt>.
187       *
188       * @param e element to be added to this set
189 <     * @return <tt>true</tt> if the set did not already contain the
189 >     * @return <tt>true</tt> if this set did not already contain the
190       *         specified element
191       * @throws ClassCastException if <tt>e</tt> cannot be compared
192 <     *         with the elements currently in the set
192 >     *         with the elements currently in this set
193       * @throws NullPointerException if the specified element is null
194       */
195      public boolean add(E e) {
# Line 192 | Line 198 | public class ConcurrentSkipListSet<E>
198  
199      /**
200       * Removes the specified element from this set if it is present.
201 +     * More formally, removes an element <tt>e</tt> such that
202 +     * <tt>o.equals(e)</tt>, if this set contains such an element.
203 +     * Returns <tt>true</tt> if this set contained the element (or
204 +     * equivalently, if this set changed as a result of the call).
205 +     * (This set will not contain the element once the call returns.)
206       *
207       * @param o object to be removed from this set, if present
208 <     * @return <tt>true</tt> if the set contained the specified element
208 >     * @return <tt>true</tt> if this set contained the specified element
209       * @throws ClassCastException if <tt>o</tt> cannot be compared
210 <     *         with the elements currently in the set
210 >     *         with the elements currently in this set
211       * @throws NullPointerException if the specified element is null
212       */
213      public boolean remove(Object o) {

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines