Chapter 10. Mediator
Ordinary object-oriented development distributes responsibility as far as it will go, with each object doing its own work independently. The OBSERVER pattern supports this distribution by minimizing the responsibility of an object that other objects find interesting. The SINGLETON pattern resists the distribution of responsibility to let you centralize respon-sibility in particular objects that clients locate and reuse. The MEDIATOR pattern too centralizes responsibility but for a particular set of objects rather than for all the clients in a system.
Providing a central authority for a group of objects is useful when the interactions the objects gravitate toward the complex condition in which every object is aware of every ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access