I re-propose attention to an old issue that has not yet been fully solved: #214
Currently jOOL offers:
Function<Tuple[N]<T...>, R> Tuple.function(Function[N]<T..., R>)
Consumer<Tuple[N]<T...>> Tuple.consumer(Consumer[N]<T...>)
But it misses:
Predicate<Tuple[N]<T...>> Tuple.predicate(Predicate[N]<T...>)
In order to beautify stream processing like that:
Seq.of(tuple("marco", 24), tuple("luigi", 16), tuple("maria", 18))
.filter(Tuple.predicate((name, age) -> age > 17))
.map(Tuple.function((name, age) -> tuple("Sir / Madame " + name, age)))
.forEach(Tuple.consumer((name, age) -> process(options, name, age)));