What is the Mediator Pattern?
Updated Apr 28, 2026
Short answer
A behavioral pattern that lets you reduce chaotic dependencies between objects by forcing them to collaborate only via a mediator object.
Deep explanation
Instead of objects interacting directly with each other (tight coupling), they communicate through a Mediator. This centralizes complex communications and control logic.
Real-world example
An air traffic control tower. Airplanes don't communicate directly with each other to land; they talk to the tower (mediator).
Common mistakes
- Creating a Mediator that handles too much logic, turning it into a massive God Object.
Follow-up questions
- How does Mediator differ from Facade?