functionalinterface
nounA special kind of computer code rule that lets you plug in a small action, like a button that does one job.
The programmer used a functional interface to tell the app what to do when the user clicks the save button.
OTHER MEANINGS
2. In Java, an interface with exactly one abstract method that can be used with lambda expressions.
Runnable is a classic functional interface because it has only one method, run().
3. A programming contract that describes one behavior so different pieces of code can swap in their own version.
By defining a functional interface, the team let each module supply its own sorting rule.
4. A design pattern where a single operation is passed around like a value.
The event system relies on a functional interface to hand off click handling to whichever component needs it.