As part of JEPs 461/473 (in OpenJDK 22, JDK 23 respectively) and JEP 485 (https://openjdk.org/jeps/485 with OpenJDK 24)
there is a very interesting extension of the OpenJDK, the so-called Stream Gatherers. They extend the Stream-API,
with the possibility to implement so-called intermediate operations. There are currently still certain limitations,
which are solvable, but do not necessarily lead to simple and maintainable code.
The presentation will provide more detailed insights into the idea and application of stream gatherers. Which problem do stream gatherers solve? How do stream gatherers compare to collectors? What possibilities do do stream gatherers offer? Examples are used to illustrate the different aspects of use.
For example, how can a more flexible distinctBy function be created? An indexed stream? A sliding window on the the stream data? A creation of groups on the stream data and much more.
Learning objectives:
* Integration and differentiation of collectors.
* Possible uses of stream gatherers.
* Understanding how stream gatherers work.
* Presentation of some example implementations.
* Comparison with other solutions.Level:Intermediate