--- jsr166/src/jsr166e/ConcurrentHashMapV8.java 2012/07/03 23:25:57 1.41 +++ jsr166/src/jsr166e/ConcurrentHashMapV8.java 2012/07/05 06:26:14 1.45 @@ -105,7 +105,7 @@ public class ConcurrentHashMapV8 */ public static interface MappingFunction { /** - * Returns a value for the given key, or null if there is no mapping + * Returns a value for the given key, or null if there is no mapping. * * @param key the (non-null) key * @return a value for the key, or null if none @@ -145,8 +145,8 @@ public class ConcurrentHashMapV8 * framework. As illustrated here, Spliterators are well suited to * designs in which a task repeatedly splits off half its work * into forked subtasks until small enough to process directly, - * and then joins these subtasks. Variants of this style can be - * also be used in completion-based designs. + * and then joins these subtasks. Variants of this style can also + * be used in completion-based designs. * *
      * {@code ConcurrentHashMapV8 m = ...
@@ -192,7 +192,7 @@ public class ConcurrentHashMapV8
          * @return a Spliterator covering approximately half of the
          * elements
          * @throws IllegalStateException if this Spliterator has
-         * already commenced traversing elements.
+         * already commenced traversing elements
          */
         Spliterator split();
 
@@ -204,7 +204,7 @@ public class ConcurrentHashMapV8
          *
          * @return a Spliterator covering the same range as this Spliterator.
          * @throws IllegalStateException if this Spliterator has
-         * already commenced traversing elements.
+         * already commenced traversing elements
          */
         Spliterator clone();
     }
@@ -759,7 +759,7 @@ public class ConcurrentHashMapV8
                     if (c != (pc = pk.getClass()) ||
                         !(k instanceof Comparable) ||
                         (dir = ((Comparable)k).compareTo((Comparable)pk)) == 0) {
-                        dir = (c == pc)? 0 : c.getName().compareTo(pc.getName());
+                        dir = (c == pc) ? 0 : c.getName().compareTo(pc.getName());
                         TreeNode r = null, s = null, pl, pr;
                         if (dir >= 0) {
                             if ((pl = p.left) != null && h <= pl.hash)
@@ -806,7 +806,7 @@ public class ConcurrentHashMapV8
         }
 
         /**
-         * Find or add a node
+         * Finds or adds a node.
          * @return null if added
          */
         @SuppressWarnings("unchecked") // suppress Comparable cast warning
@@ -823,7 +823,7 @@ public class ConcurrentHashMapV8
                     if (c != (pc = pk.getClass()) ||
                         !(k instanceof Comparable) ||
                         (dir = ((Comparable)k).compareTo((Comparable)pk)) == 0) {
-                        dir = (c == pc)? 0 : c.getName().compareTo(pc.getName());
+                        dir = (c == pc) ? 0 : c.getName().compareTo(pc.getName());
                         TreeNode r = null, s = null, pl, pr;
                         if (dir >= 0) {
                             if ((pl = p.left) != null && h <= pl.hash)
@@ -1017,7 +1017,7 @@ public class ConcurrentHashMapV8
                                     sib = (xp = x.parent) == null ? null : xp.right;
                                 }
                                 if (sib != null) {
-                                    sib.red = (xp == null)? false : xp.red;
+                                    sib.red = (xp == null) ? false : xp.red;
                                     if ((sr = sib.right) != null)
                                         sr.red = false;
                                 }
@@ -1055,7 +1055,7 @@ public class ConcurrentHashMapV8
                                     sib = (xp = x.parent) == null ? null : xp.left;
                                 }
                                 if (sib != null) {
-                                    sib.red = (xp == null)? false : xp.red;
+                                    sib.red = (xp == null) ? false : xp.red;
                                     if ((sl = sib.left) != null)
                                         sl.red = false;
                                 }
@@ -2012,8 +2012,8 @@ public class ConcurrentHashMapV8
     }
 
     /**
-     * Split a normal bin with list headed by e into lo and hi parts;
-     * install in given table
+     * Splits a normal bin with list headed by e into lo and hi parts;
+     * installs in given table.
      */
     private static void splitBin(Node[] nextTab, int i, Node e) {
         int bit = nextTab.length >>> 1; // bit to split on
@@ -2043,7 +2043,7 @@ public class ConcurrentHashMapV8
     }
 
     /**
-     * Split a tree bin into lo and hi parts; install in given table
+     * Splits a tree bin into lo and hi parts; installs in given table.
      */
     private static void splitTreeBin(Node[] nextTab, int i, TreeBin t) {
         int bit = nextTab.length >>> 1;