↓ Skip to main content

Interface

Consumer <Intf>

Consumer

The utility package java.util.function has this functional interface Consumer. Each functional interface (Annotated with @FunctionalInterface) conceptually has a single method (abstract) called the functional method to which the lambda expression’s parameter and return types are matched against. Functional interfaces often represent abstract concepts like functions, actions, or predicates.