The lambda expression is the most important new feature in Java SE 8. Long considered a missing feature in Java, it has made the Java language complete. At least for now. In this chapter you will learn what lambda expressions are and why they are a nice addition to the language. You will also be introduced to new technical terms such as single abstract method (SAM) and functional interface as well as learn about method references.
Why Lambda Expressions?
Also known as closures, lambda expressions can make certain constructs shorter and more readable, especially when you are dealing with inner classes.
Consider the following code snippet that defines an anonymous inner class out of the java.lang.Runnable interface ...