You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The mediator pattern defines an object that encapsulates how a set of objects interact. This pattern is considered to be a behavioural pattern due to the way it can alter the program's running behaviour.
Usage:
Components need to communicate with each other
They communicate via the mediator
The components all have knowledge of the mediator
Advantages:
Hides coordination between components
Component no longer need to know about each other
Mediator turns many to many relationships into one to many/many to one.
Disadvantages:
The mediator can become large and very complicated