Skip to content

Instantly share code, notes, and snippets.

@DannyRusnok
Created April 16, 2020 17:09
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save DannyRusnok/2e353892daf77d3a669e8f015c715304 to your computer and use it in GitHub Desktop.
Save DannyRusnok/2e353892daf77d3a669e8f015c715304 to your computer and use it in GitHub Desktop.
class Program
{
static void Main(string[] args){
var mediator = new ConcreteMediator();
var c1 = new Colleague1(mediator);
var c2 = new Colleague2(mediator);
mediator.Colleague1 = c1;
mediator.Colleague2 = c2;
c1.Send("Hello, World! (from c1)");
c2.Send("Hello, World! (from c2)");
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment