Open main menu
Home
Random
Recent changes
Special pages
Community portal
Preferences
About Wikipedia
Disclaimers
Incubator escapee wiki
Search
User menu
Talk
Dark mode
Contributions
Create account
Log in
Editing
Mediator pattern
(section)
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
== Definition == The essence of the mediator pattern is to "define an object that encapsulates how a set of objects interact". It promotes loose coupling by keeping objects from referring to each other explicitly, and it allows their interaction to be varied independently.<ref>{{cite book |first1=Erich |last1=Gamma |author-link1=Erich Gamma |first2=Richard |last2=Helm |first3=Ralph |last3=Johnson |author-link3=Ralph Johnson (computer scientist) |first4=John |last4=Vlissides |author-link4=John Vlissides |title=[[Design Patterns]] |date= 1994 |publisher=[[Addison-Wesley]] |isbn=0-201-63361-2}}</ref><ref>{{cite web |url=http://sourcemaking.com/design_patterns/mediator |title=Mediator Design Pattern |website= SourceMaking}}</ref> Client classes can use the mediator to send messages to other clients, and can receive messages from other clients via an event on the mediator class.
Edit summary
(Briefly describe your changes)
By publishing changes, you agree to the
Terms of Use
, and you irrevocably agree to release your contribution under the
CC BY-SA 4.0 License
and the
GFDL
. You agree that a hyperlink or URL is sufficient attribution under the Creative Commons license.
Cancel
Editing help
(opens in new window)