Re: Potential additional DGM methods

2025-03-25 Thread Mattias Reichel
I think "injectMany" would be a good addition. It looks like a useful feature and it's important to keep up with the features added in Java. Some silly brainstorming for method name: injectAccumulate (or injectAcc) injectAll /Mattias Den tis 25 mars 2025 kl 13:30 skrev Paul King : > Hi folks, >

Potential additional DGM methods

2025-03-25 Thread Paul King
Hi folks, JDK24 brought with it the Gatherers API for enhanced stream processing. In traditional streams, we have the normal reduce operators, e.g.: var nums = 1..3 assert nums.stream().reduce('', (String string, number) -> string + number) == '123' Groovy supports this for collections using "i