Class StreamGatherersPreviewNotes
java.lang.Object
net.jrodolfo.java_evolution.java22.stream_gatherers.StreamGatherersPreviewNotes
Explains Stream Gatherers, introduced as a Java 22 preview feature.
Streams already had many built-in intermediate operations, such as
map, filter, and limit. Some transformations were
still awkward because they needed buffering, state, or a custom rule for
when to emit output elements. Gatherers were introduced as a standard
extension point for those custom intermediate stream operations.
This Java 22 package keeps the feature explanatory because gatherers were still preview in Java 22. The final runnable example lives in the Java 24 package, where Stream Gatherers became final.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionNames transformations that show why gatherers are useful.nextStep()Points learners to the final Java 24 example.Explains the preview status.Explains the central problem.Explains the central API idea.
-
Constructor Details
-
StreamGatherersPreviewNotes
public StreamGatherersPreviewNotes()
-
-
Method Details
-
problemSolved
-
whatJavaIntroduced
-
exampleUseCases
Names transformations that show why gatherers are useful.- Returns:
- example transformations
-
previewStatus
-
nextStep
Points learners to the final Java 24 example.- Returns:
- a short next-step note
-