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

Comparing jsr166/src/jsr166e/ConcurrentHashMapV8.java (file contents):
Revision 1.77 by jsr166, Sun Nov 18 03:07:22 2012 UTC vs.
Revision 1.78 by jsr166, Sun Nov 18 18:03:10 2012 UTC

# Line 40 | Line 40 | import java.io.Serializable;
40   * interoperable with {@code Hashtable} in programs that rely on its
41   * thread safety but not on its synchronization details.
42   *
43 < * <p> Retrieval operations (including {@code get}) generally do not
43 > * <p>Retrieval operations (including {@code get}) generally do not
44   * block, so may overlap with update operations (including {@code put}
45   * and {@code remove}). Retrievals reflect the results of the most
46   * recently <em>completed</em> update operations holding upon their
# Line 61 | Line 61 | import java.io.Serializable;
61   * that may be adequate for monitoring or estimation purposes, but not
62   * for program control.
63   *
64 < * <p> The table is dynamically expanded when there are too many
64 > * <p>The table is dynamically expanded when there are too many
65   * collisions (i.e., keys that have distinct hash codes but fall into
66   * the same slot modulo the table size), with the expected average
67   * effect of maintaining roughly two bins per mapping (corresponding
# Line 82 | Line 82 | import java.io.Serializable;
82   * {@code hashCode()} is a sure way to slow down performance of any
83   * hash table.
84   *
85 < * <p> A {@link Set} projection of a ConcurrentHashMapV8 may be created
85 > * <p>A {@link Set} projection of a ConcurrentHashMapV8 may be created
86   * (using {@link #newKeySet()} or {@link #newKeySet(int)}), or viewed
87   * (using {@link #keySet(Object)} when only keys are of interest, and the
88   * mapped values are (perhaps transiently) not used or all take the
89   * same mapping value.
90   *
91 < * <p> A ConcurrentHashMapV8 can be used as scalable frequency map (a
91 > * <p>A ConcurrentHashMapV8 can be used as scalable frequency map (a
92   * form of histogram or multiset) by using {@link LongAdder} values
93   * and initializing via {@link #computeIfAbsent}. For example, to add
94   * a count to a {@code ConcurrentHashMapV8<String,LongAdder> freqs}, you
# Line 99 | Line 99 | import java.io.Serializable;
99   * <em>optional</em> methods of the {@link Map} and {@link Iterator}
100   * interfaces.
101   *
102 < * <p> Like {@link Hashtable} but unlike {@link HashMap}, this class
102 > * <p>Like {@link Hashtable} but unlike {@link HashMap}, this class
103   * does <em>not</em> allow {@code null} to be used as a key or value.
104   *
105   * <p>ConcurrentHashMapV8s support parallel operations using the {@link
# Line 184 | Line 184 | import java.io.Serializable;
184   * arguments can be supplied using {@code new
185   * AbstractMap.SimpleEntry(k,v)}.
186   *
187 < * <p> Bulk operations may complete abruptly, throwing an
187 > * <p>Bulk operations may complete abruptly, throwing an
188   * exception encountered in the application of a supplied
189   * function. Bear in mind when handling such exceptions that other
190   * concurrently executing functions could also have thrown
# Line 199 | Line 199 | import java.io.Serializable;
199   * Similarly, parallelization may not lead to much actual parallelism
200   * if all processors are busy performing unrelated tasks.
201   *
202 < * <p> All arguments to all task methods must be non-null.
202 > * <p>All arguments to all task methods must be non-null.
203   *
204   * <p><em>jsr166e note: During transition, this class
205   * uses nested functional interfaces with different names but the
# Line 225 | Line 225 | public class ConcurrentHashMapV8<K, V>
225       * portion of the elements, and so may be amenable to parallel
226       * execution.
227       *
228 <     * <p> This interface exports a subset of expected JDK8
228 >     * <p>This interface exports a subset of expected JDK8
229       * functionality.
230       *
231       * <p>Sample usage: Here is one (of the several) ways to compute
# Line 2713 | Line 2713 | public class ConcurrentHashMapV8<K, V>
2713       * Maps the specified key to the specified value in this table.
2714       * Neither the key nor the value can be null.
2715       *
2716 <     * <p> The value can be retrieved by calling the {@code get} method
2716 >     * <p>The value can be retrieved by calling the {@code get} method
2717       * with a key that is equal to the original key.
2718       *
2719       * @param key key with which the specified value is to be associated

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines