I'm just trying out lambdas in Java 8 and I'm quite disappointed because I cannot use them for instance on a plain List
. Instead I always have to convert the List
to a Stream
and then convert back again via .collect()
.
Is this the ways it's supposed to be or am I doing something wrong? Maybe the solution is to replace uses of the good old Collection with Stream where possible so .map and .filter can be used more naturally everywhere. However, I'm not sure whether this is considered good practice. Am I missing another trick to work around this problem?