<html><head></head><body>Wow, this is great news!<br>
It may allow us to write a wrapper for chmv8 in Scala parallel collections. I wish concurrent skip lists had a similar thing.<br>
<br>
Cheers,<br>
Alex<br>
-- <br>
Aleksandar Prokopec<br>
LAMP, IC, EPFL<br>
<br>
Sent from my Android phone with K-9 Mail. Please excuse my brevity.<br><br><div class="gmail_quote">Doug Lea <dl@cs.oswego.edu> wrote:<blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
<pre style="white-space: pre-wrap; word-wrap:break-word; font-family: sans-serif"><br />In addition to including the compute/computeIfAbsent changes<br />discussed on this list last week, the updated version of<br />ConcurrentHashMapV8 contains basic support for performing<br />parallel (normally via ForkJoin) operations on the keys,<br />values, or entries of a map.<br /><br />The added Spliterator interface (see<br /><a href="http://gee.cs.oswego.edu/dl/jsr166/dist/jsr166edocs/jsr166e/ConcurrentHashMapV8.Spliterator.html">http://gee.cs.oswego.edu/dl/jsr166/dist/jsr166edocs/jsr166e/ConcurrentHashMapV8.Spliterator.html</a>)<br />is for now a nested interface that contains a subset of<br />some functionality likely to be available in JDK8.<br />There are also three new methods to provide them:<br />   public Spliterator<K> keySpliterator()<br />   public Spliterator<V> valueSpliterator()<br />   public Spliterator<Map.Entry<K,V>> entrySpliterator()<br />See
the Spliterator javadocs for a usage example.<br /><br />These methods only provide a foothold for writing your<br />own parallel operations. CHMV8 doesn't now itself supply<br />the map, filter, reduce, forEach, etc operations expected<br />to be supported under JDK8 lambda-ized collections. However,<br />they do enable those familiar with ForkJoin programming<br />to get a head start evaluating such code you write yourself.<br />If you do this, please report back any interesting experiences.<br /><br />The usual links:<br />     *  API specs:  <a href="http://gee.cs.oswego.edu/dl/jsr166/dist/jsr166edocs">http://gee.cs.oswego.edu/dl/jsr166/dist/jsr166edocs</a>/<br />     * jar file: <a href="http://gee.cs.oswego.edu/dl/jsr166/dist/jsr166e.jar">http://gee.cs.oswego.edu/dl/jsr166/dist/jsr166e.jar</a> (compiled <br />using Java7 javac).<br />     * Browsable CVS sources: <br /><a
href="http://gee.cs.oswego.edu/cgi-bin/viewcvs.cgi/jsr166/src/jsr166e">http://gee.cs.oswego.edu/cgi-bin/viewcvs.cgi/jsr166/src/jsr166e</a>/<br /><br />-Doug<br /><br /><hr /><br />Concurrency-interest mailing list<br />Concurrency-interest@cs.oswego.edu<br /><a href="http://cs.oswego.edu/mailman/listinfo/concurrency-interest">http://cs.oswego.edu/mailman/listinfo/concurrency-interest</a><br /></pre></blockquote></div></body></html>