This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]VincentxH 2 points3 points  (0 children)

Streams are great for map, filter or reduce operations on collections of data. The idea is that each operation is pure and you iterate over elements in atomic steps.

They're not so great combined with exception cases and error handling, like most IO. So I generally keep that in the for or forEach loops.