Multiple choice technology programming languages

When would you use the Mediator pattern?

  1. When you need to co-ordinate state changes between other objects by using one object.

  2. When you need to add functionality to a class without changing its interface.

  3. When you need create a separation between abstractions and classes that implement those abstractions.

  4. You need a class that will be used in lots of different applications where the logic will only change slightly.

Reveal answer Fill a bubble to check yourself
A Correct answer
Explanation

Mediator centralizes communication between objects, coordinating state changes through ONE object. Option A directly describes this: coordinating state changes using a central mediator. Adapter converts interfaces, Bridge separates abstraction from implementation, and Template Method varies algorithm steps - none focus on coordination.