예제 #1
0
 public void Encode(VideoEncoder video)
 {
     foreach (var channel in _notificationChannels)
     {
         channel.Send(new Message());
     }
 }
예제 #2
0
        static void Main(string[] args)
        {
            var encoder = new VideoEncoder();

            encoder.RegisterNotificationChannel(new MailNotificationChannel());
            encoder.RegisterNotificationChannel(new SmsNotificationChannel());
            encoder.Encode(new Video());
        }
예제 #3
0
        static void Main(string[] args)
        {
            var encoder = new VideoEncoder();

            encoder.RegisterNotificationChanel(new MailNotificationChanel());
            encoder.RegisterNotificationChanel(new SMSNotificationChanel());
            encoder.Encode(new Video());


            Console.WriteLine("Finish");
            Console.ReadKey();
        }