121 |
|
* being concurrently updated by other threads; for example, when |
122 |
|
* computing a snapshot summary of the values in a shared registry. |
123 |
|
* There are three kinds of operation, each with four forms, accepting |
124 |
< |
* functions with Keys, Values, Entries, and (Key, Value) arguments |
125 |
< |
* and/or return values. Because the elements of a ConcurrentHashMap |
126 |
< |
* are not ordered in any particular way, and may be processed in |
127 |
< |
* different orders in different parallel executions, the correctness |
128 |
< |
* of supplied functions should not depend on any ordering, or on any |
129 |
< |
* other objects or values that may transiently change while |
130 |
< |
* computation is in progress; and except for forEach actions, should |
131 |
< |
* ideally be side-effect-free. Bulk operations on {@link java.util.Map.Entry} |
132 |
< |
* objects do not support method {@code setValue}. |
124 |
> |
* functions with keys, values, entries, and (key, value) pairs as |
125 |
> |
* arguments and/or return values. Because the elements of a |
126 |
> |
* ConcurrentHashMap are not ordered in any particular way, and may be |
127 |
> |
* processed in different orders in different parallel executions, the |
128 |
> |
* correctness of supplied functions should not depend on any |
129 |
> |
* ordering, or on any other objects or values that may transiently |
130 |
> |
* change while computation is in progress; and except for forEach |
131 |
> |
* actions, should ideally be side-effect-free. Bulk operations on |
132 |
> |
* {@link java.util.Map.Entry} objects do not support method {@code |
133 |
> |
* setValue}. |
134 |
|
* |
135 |
|
* <ul> |
136 |
|
* <li> forEach: Perform a given action on each element. |