# Null Object: A Safe Stand-In for Nothing

When a room has no speaker, every routine that plays something has to check for null first, and the one that forgets crashes the morning; a Null Object gives the room a speaker that safely does nothing, so the routines need no checks at all.

![Cheat sheet: Null Object: A Safe Stand-In for Nothing](https://fsdtrainingmedia.blob.core.windows.net/public/images/2026/11/b6af106d5d4d4d74b4eaf9f78e97d270.webp)

- Category: Data Structures
- Level: Journeyman
- Tags: Code Smell, Null, Null Object Pattern, OOP
- Author: Gregor Dzierzon
- Updated: November 17, 2026

Source: https://www.ask-codey.com/cheat-sheets/dp-null-object-cheat-sheet
