Module 04 of 10

Modern Java: Lambdas, Streams & Records

Lessons

About This Module

Java has changed a lot since its early days. Modern Java lets you say the same thing in far fewer lines, and most code you'll meet in real projects uses these newer features. This module teaches the style that makes today's Java concise and expressive.

You'll start with lambdas and functional interfaces, which let you pass behaviour around as easily as data. Then you'll use the Stream API to filter, transform, and collect data in a readable pipeline, along with Optional for handling missing values safely. Finally you'll see newer language features: records for compact data classes and sealed classes for controlled type hierarchies.

With a modern toolkit in place, you'll be ready for the next module, Exceptions, I/O & Concurrency, which covers error handling, working with files, and running tasks in parallel.

Lessons

4 videos
01

Functional Interfaces and Lambda Expressions in Java

A crash course on what a functional interface is and how lambda expressions implement one in a single line.

02

Java Streams API: The Basics

An introduction to the Stream API, how a stream pipeline works, and the idea behind intermediate and terminal operations.

03

Java 8 Stream API Tutorial

A complete beginner course on functional programming with streams: filtering, mapping, collecting, and more.

04

Records, Sealed Classes & Pattern Matching

How records, sealed classes, and pattern matching, added in recent Java versions, make data modelling shorter and safer.