Point lambdaification of List/Set/Map
scolebourne at joda.org
Mon Jun 24 08:14:14 PDT 2013
One point lambdaification that I haven't seen mentioned is addition
static factory methods for the main collection interfaces. (Strictly,
this proposal is not point lambdaification as it does not involve
lambdas, but it is very much in the same area).
I propose adding these static methods:
Each of these methods would return immutable implementations.
There is a case for extending the methods to Iterator and other
collection types, however these are the most important.
These follow the designs of Stream static methods IIRC.
This library change would remove much of the requirement for the
"collection literals" change discussed in Project Coin.
Implementation would ideally be via new dedicated immutable classes,
however space could be saved by simply reusing the existing classes.
Is this something we could fit in? (Is resourcing the problem, or the idea?)
More information about the lambda-dev