--- jsr166/src/jsr166e/ConcurrentHashMapV8.java 2013/01/19 20:39:43 1.89 +++ jsr166/src/jsr166e/ConcurrentHashMapV8.java 2013/02/11 15:25:20 1.94 @@ -1785,8 +1785,10 @@ public class ConcurrentHashMapV8 } } if (len != 0) { - if (len > 1) + if (len > 1) { addCount(delta, len); + delta = 0L; + } break; } } @@ -1975,7 +1977,7 @@ public class ConcurrentHashMapV8 } } - /* + /** * Moves and/or copies the nodes in each bin to new table. See * above for explanation. */ @@ -2892,8 +2894,7 @@ public class ConcurrentHashMapV8 * course only appropriate if it is acceptable to use the same * value for all additions from this view. * - * @param mappedValue the mapped value to use for any - * additions. + * @param mappedValue the mapped value to use for any additions * @return the set view * @throws NullPointerException if the mappedValue is null */ @@ -3371,8 +3372,8 @@ public class ConcurrentHashMapV8 * of each (key, value). * * @param transformer a function returning the transformation - * for an element, or null of there is no transformation (in - * which case the action is not applied). + * for an element, or null if there is no transformation (in + * which case the action is not applied) * @param action the action */ @SuppressWarnings("unchecked") public void forEachSequentially @@ -3415,8 +3416,8 @@ public class ConcurrentHashMapV8 * combine values, or null if none. * * @param transformer a function returning the transformation - * for an element, or null of there is no transformation (in - * which case it is not combined). + * for an element, or null if there is no transformation (in + * which case it is not combined) * @param reducer a commutative associative combining function * @return the result of accumulating the given transformation * of all (key, value) pairs @@ -3528,8 +3529,8 @@ public class ConcurrentHashMapV8 * of each key. * * @param transformer a function returning the transformation - * for an element, or null of there is no transformation (in - * which case the action is not applied). + * for an element, or null if there is no transformation (in + * which case the action is not applied) * @param action the action */ @SuppressWarnings("unchecked") public void forEachKeySequentially @@ -3593,8 +3594,8 @@ public class ConcurrentHashMapV8 * null if none. * * @param transformer a function returning the transformation - * for an element, or null of there is no transformation (in - * which case it is not combined). + * for an element, or null if there is no transformation (in + * which case it is not combined) * @param reducer a commutative associative combining function * @return the result of accumulating the given transformation * of all keys @@ -3706,8 +3707,8 @@ public class ConcurrentHashMapV8 * of each value. * * @param transformer a function returning the transformation - * for an element, or null of there is no transformation (in - * which case the action is not applied). + * for an element, or null if there is no transformation (in + * which case the action is not applied) */ public void forEachValueSequentially (Fun transformer, @@ -3766,8 +3767,8 @@ public class ConcurrentHashMapV8 * null if none. * * @param transformer a function returning the transformation - * for an element, or null of there is no transformation (in - * which case it is not combined). + * for an element, or null if there is no transformation (in + * which case it is not combined) * @param reducer a commutative associative combining function * @return the result of accumulating the given transformation * of all values @@ -3880,8 +3881,8 @@ public class ConcurrentHashMapV8 * of each entry. * * @param transformer a function returning the transformation - * for an element, or null of there is no transformation (in - * which case the action is not applied). + * for an element, or null if there is no transformation (in + * which case the action is not applied) * @param action the action */ @SuppressWarnings("unchecked") public void forEachEntrySequentially @@ -3943,8 +3944,8 @@ public class ConcurrentHashMapV8 * or null if none. * * @param transformer a function returning the transformation - * for an element, or null of there is no transformation (in - * which case it is not combined). + * for an element, or null if there is no transformation (in + * which case it is not combined) * @param reducer a commutative associative combining function * @return the result of accumulating the given transformation * of all entries @@ -4055,8 +4056,8 @@ public class ConcurrentHashMapV8 * of each (key, value). * * @param transformer a function returning the transformation - * for an element, or null of there is no transformation (in - * which case the action is not applied). + * for an element, or null if there is no transformation (in + * which case the action is not applied) * @param action the action */ public void forEachInParallel @@ -4090,8 +4091,8 @@ public class ConcurrentHashMapV8 * combine values, or null if none. * * @param transformer a function returning the transformation - * for an element, or null of there is no transformation (in - * which case it is not combined). + * for an element, or null if there is no transformation (in + * which case it is not combined) * @param reducer a commutative associative combining function * @return the result of accumulating the given transformation * of all (key, value) pairs @@ -4178,8 +4179,8 @@ public class ConcurrentHashMapV8 * of each key. * * @param transformer a function returning the transformation - * for an element, or null of there is no transformation (in - * which case the action is not applied). + * for an element, or null if there is no transformation (in + * which case the action is not applied) * @param action the action */ public void forEachKeyInParallel @@ -4227,8 +4228,8 @@ public class ConcurrentHashMapV8 * null if none. * * @param transformer a function returning the transformation - * for an element, or null of there is no transformation (in - * which case it is not combined). + * for an element, or null if there is no transformation (in + * which case it is not combined) * @param reducer a commutative associative combining function * @return the result of accumulating the given transformation * of all keys @@ -4315,8 +4316,8 @@ public class ConcurrentHashMapV8 * of each value. * * @param transformer a function returning the transformation - * for an element, or null of there is no transformation (in - * which case the action is not applied). + * for an element, or null if there is no transformation (in + * which case the action is not applied) */ public void forEachValueInParallel (Fun transformer, @@ -4362,8 +4363,8 @@ public class ConcurrentHashMapV8 * null if none. * * @param transformer a function returning the transformation - * for an element, or null of there is no transformation (in - * which case it is not combined). + * for an element, or null if there is no transformation (in + * which case it is not combined) * @param reducer a commutative associative combining function * @return the result of accumulating the given transformation * of all values @@ -4450,8 +4451,8 @@ public class ConcurrentHashMapV8 * of each entry. * * @param transformer a function returning the transformation - * for an element, or null of there is no transformation (in - * which case the action is not applied). + * for an element, or null if there is no transformation (in + * which case the action is not applied) * @param action the action */ public void forEachEntryInParallel @@ -4498,8 +4499,8 @@ public class ConcurrentHashMapV8 * or null if none. * * @param transformer a function returning the transformation - * for an element, or null of there is no transformation (in - * which case it is not combined). + * for an element, or null if there is no transformation (in + * which case it is not combined) * @param reducer a commutative associative combining function * @return the result of accumulating the given transformation * of all entries @@ -4714,7 +4715,7 @@ public class ConcurrentHashMapV8 * A view of a ConcurrentHashMapV8 as a {@link Set} of keys, in * which additions may optionally be enabled by mapping to a * common value. This class cannot be directly instantiated. See - * {@link #keySet}, {@link #keySet(Object)}, {@link #newKeySet()}, + * {@link #keySet()}, {@link #keySet(Object)}, {@link #newKeySet()}, * {@link #newKeySet(int)}. */ public static class KeySetView extends CHMView @@ -4731,7 +4732,7 @@ public class ConcurrentHashMapV8 * or {@code null} if additions are not supported. * * @return the default mapped value for additions, or {@code null} - * if not supported. + * if not supported */ public V getMappedValue() { return value; } @@ -4970,7 +4971,7 @@ public class ConcurrentHashMapV8 * @param map the map * @param transformer a function returning the transformation * for an element, or null if there is no transformation (in - * which case it is not combined). + * which case it is not combined) * @param reducer a commutative associative combining function * @return the task */ @@ -5137,7 +5138,7 @@ public class ConcurrentHashMapV8 * @param map the map * @param transformer a function returning the transformation * for an element, or null if there is no transformation (in - * which case it is not combined). + * which case it is not combined) * @param reducer a commutative associative combining function * @return the task */ @@ -5303,7 +5304,7 @@ public class ConcurrentHashMapV8 * @param map the map * @param transformer a function returning the transformation * for an element, or null if there is no transformation (in - * which case it is not combined). + * which case it is not combined) * @param reducer a commutative associative combining function * @return the task */ @@ -5469,7 +5470,7 @@ public class ConcurrentHashMapV8 * @param map the map * @param transformer a function returning the transformation * for an element, or null if there is no transformation (in - * which case it is not combined). + * which case it is not combined) * @param reducer a commutative associative combining function * @return the task */