functional-reactive
Made in the European Union

Transformations

Curry, uncurry and stream transformations.

Static helpers for working with multi-argument functions:

  • curryBiFunction() / unCurryBiFunction()
  • curryTriFunction() / unCurryTriFunction()
  • curryCheckedBiFunction() / unCurryCheckedBiFunction()
  • iteratorToStream()
BiFunction<Integer, Integer, Integer> add = Integer::sum;
Function<Integer, Function<Integer, Integer>> curried =
    Transformations.<Integer, Integer, Integer>curryBiFunction().apply(add);

curried.apply(2).apply(3); // 5