Text blocks and whitespace stripping, Records and their generated canonical constructor, compact constructors for validation, sealed classes with permits, sealed+records for algebraic data types, instanceof pattern matching, switch expressions with yield, and guarded patterns in Java 21.
// Lessons
- 01soon
Text Blocks (Java 13) — Multiline Strings Without Escape Chaos
- 02soon
Records (Java 16) — Immutable Data Classes Without the Boilerplate
- 03soon
Record Internals — The Generated Canonical Constructor and Accessors
- 04soon
Compact Constructors — Validation Without Boilerplate
- 05soon
Sealed Classes (Java 17) — Restricting the Class Hierarchy
- 06soon
Sealed Classes + Records — Algebraic Data Types in Java
- 07soon
instanceof Pattern Matching (Java 16) — Eliminating the Cast
- 08soon
Switch Expressions (Java 14) — yield and Arrow Cases
- 09soon
Switch with Pattern Matching (Java 21) — Guarded Patterns