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

Comparing jsr166/src/main/java/util/concurrent/ConcurrentSkipListMap.java (file contents):
Revision 1.6 by dl, Tue Mar 22 01:30:18 2005 UTC vs.
Revision 1.7 by dl, Tue Mar 22 16:48:38 2005 UTC

# Line 2269 | Line 2269 | public class ConcurrentSkipListMap<K,V>
2269       *               <tt>null</tt>.
2270       */
2271      public SortedMap<K,V> subMap(K fromKey, K toKey) {
2272 <        if (fromKey == null || toKey == null)
2273 <            throw new NullPointerException();
2274 <        return new ConcurrentSkipListSubMap(this, fromKey, toKey);
2272 >        return navigableSubMap(fromKey, toKey);
2273      }
2274  
2275      /**
# Line 2287 | Line 2285 | public class ConcurrentSkipListMap<K,V>
2285       * @throws NullPointerException if <tt>toKey</tt> is <tt>null</tt>.
2286       */
2287      public SortedMap<K,V> headMap(K toKey) {
2288 <        if (toKey == null)
2291 <            throw new NullPointerException();
2292 <        return new ConcurrentSkipListSubMap(this, null, toKey);
2288 >        return navigableHeadMap(toKey);
2289      }
2290  
2291      /**
# Line 2305 | Line 2301 | public class ConcurrentSkipListMap<K,V>
2301       * @throws NullPointerException if <tt>fromKey</tt> is <tt>null</tt>.
2302       */
2303      public SortedMap<K,V>  tailMap(K fromKey) {
2304 <        if (fromKey == null)
2309 <            throw new NullPointerException();
2310 <        return new ConcurrentSkipListSubMap(this, fromKey, null);
2304 >        return navigableTailMap(fromKey);
2305      }
2306  
2307      /* ---------------- Relational operations -------------- */

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines