Example #1
0
        static void Main(string[] args)
        {
            Mediator mediator = new Mediator();

            Teacher bahri = new Teacher(mediator);

            bahri.Name = "Bahri";

            mediator.Teacher = bahri;

            Student koc = new Student(mediator);

            koc.Name = "KOÇ";

            Student sarı = new Student(mediator);

            sarı.Name = "sarı";

            mediator.Students = new List <Student> {
                koc, sarı
            };

            bahri.SendNewImageUrl("slide.jpg");
            bahri.RecieveQuetion("Is it true?", sarı);
            Console.ReadLine();
        }
Example #2
0
 public void SendQuetion(string question, Student student)
 {
     Teacher.RecieveQuetion(question, student);
 }