O'Reilly logo

Java 9 Concurrency Cookbook - Second Edition by Javier Fernández González

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

There's more...

ConcurrentHashMap has more methods than what's specified in the previous section. We enumerate some of them in the following list:

  • forEachKey() and forEachValue(): These methods are similar to the forEach() methods, but in this case, the expression processes the keys and values stored in ConcurrentHashMap, respectively.
  • searchEntries(), searchKeys(), and searchValues(): These methods are similar to the search() method explained before. However, in this case, the expression passed as a parameter receives an Entry object, a key, or a value of the elements stored in ConcurrentHashMap.
  • reduceEntries(), reduceKeys(), and reduceValues(): These methods are similar to the reduce() method explained before. However, in this case, the ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required