Collectors inventory
Brian Goetz
brian.goetz at oracle.com
Thu Mar 7 15:09:20 PST 2013
Update on this:
On 2/21/2013 6:01 PM, Brian Goetz wrote:
> As I promised a long time ago, here's an overview of what's in
> Collectors currently.
>
> There are 12 basic forms:
> - toCollection(ctor)
> - toList()
> - toSet()
> - toStringBuilder()
> - toStringJoiner(delimiter)
> - to{Long,Double}Statistics
To this group, we'll add:
toMap -- two forms (explicit map ctor and not)
toConcurrentMap -- two forms (same)
and get rid of the four forms of joiningWith in each of Collectors and
ConcurrentCollectors.
This leaves us with the more complex mess of:
> - groupingBy(classifier, mapFactory, downstream collector)
> - groupingReduce(classifier, mapFactory, mapper, reducer)
> - partitioningBy(predicate, downstream collector)
> - partitioningReduce(predicate, mapper, reducer)
for which a new story is being prepared, stay tuned.
More information about the lambda-libs-spec-experts
mailing list