mappedTo -> join? (original) (raw)

Raab, Donald Donald.Raab at gs.com
Tue Jan 8 18:38:49 PST 2013


+1

toMap works for me.

join is already too overloaded. On Tue, Jan 8, 2013 at 1:11 PM, Remi Forax <forax at univ-mlv.fr<mailto:forax at univ-mlv.fr>> wrote: On 01/08/2013 06:12 PM, Brian Goetz wrote: One of the reducers we've got takes a Stream and a function T->U and creates a Map<T,U>. Currently we call this "mappedTo". Should this be called "join" instead? Or mapJoin?

Map<Person, Integer> map = people.reduce(mappedTo(Person::getAge))); vs Map<Person, Integer> map = people.reduce(join(Person::getAge))); Map<Person, Integer> map = people.reduce(mapJoin(Person::getAge)));

or just toMap, Map<Person, Integer> map = people.reduce(Reducer.toMap(Person::getAge)));

Rémi



More information about the lambda-libs-spec-observers mailing list