functional-interfaces
3 tutorials tagged “functional-interfaces”.
- Built-In Functional Interfaces in JavaThe java.util.function package: Predicate, Function, Consumer, Supplier, UnaryOperator, BinaryOperator and BiFunction, with their methods and examples.
- Composing Functions in JavaBuild bigger functions from small ones with andThen, compose, and, or, negate, Predicate.not and Function.identity. Learn each with examples.
- Primitive Functional Interfaces in JavaIntPredicate, IntFunction, ToIntFunction, IntUnaryOperator and friends avoid boxing when lambdas work with int, long and double. Learn them with examples.