13. Functional Programming with Lambda Expressions
Overview
This chapter discusses how Java doubles up as a functional programming language. It also details the manner in which lambda expressions are used to perform pattern matching in Java. It accomplishes this, first, by explaining, in general terms, the difference between Object-Oriented Programming (OOP) and Functional Programming (FP). You will then learn the basic definition of a pure function, as well as the difference between functional and normal interfaces. And, finally, you practice employing lambda expressions as callbacks to events and using them to filter data.
Introduction
While Java has been around for over 20 years now, and Functional Programming (FP) has been around for ...
Get The Java Workshop now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.