Re:Net 9.0 LINQ Performance Improvements
by Rohansi on Friday October 18, 2024 @09:50AM
(#41879467)
One of the unfortunate pieces missing from Java's streams is the ability to easily extend them with additional operators. In C# they are all extension methods for the IEnumerable interface so you can add your own methods into the chain but that's not possible in Java.
[ Parent
| on HN ]
It is coming, it is called Gatherers, another approach, same result.
I'm a huge fan of Gatherers, lovely API!
Good that there's a solution coming up but it's not as nice as C# IMO. Gatherers are way more verbose both in usage and especially in implementation. In C# they can be written as generator methods which is a very intuitive way to work with streams of data.