Type a @FunctionalInterface declaration
Type a @FunctionalInterface declaration
Answer
@FunctionalInterface interface Transformer { String transform(String input); }
The annotation is optional but strongly recommended: it makes the compiler enforce the one-abstract-method rule and makes the design intent explicit to readers.