Exemple #1
0
        static void Main()
        {
            var notifier = new Notifier();
            var client = new Client(notifier);

            notifier.DoSomething();

            var badClient = new BadClient(notifier);
            notifier.DelegateNotEvent.Invoke();
        }
Exemple #2
0
 public BadClient(Notifier notifier)
 {
     notifier.DelegateNotEvent = NotifierDelegateInvoked;
 }
Exemple #3
0
 public Client(Notifier notifier)
 {
     notifier.SomethingHappened += NotifierOnSomethingHappened;
 }