예제 #1
0
        static void Main(string[] args)
        {
            MovieTickets mt = new MovieTickets();
            TicketSales  ts = new TicketSales();

            ts.Subscribe(mt);
            mt.PurchaseTickets(new DateTime(2016, 3, 25), "Split");
            Console.Read();
        }
예제 #2
0
 public void Subscribe(MovieTickets tickets)
 {
     tickets.MovieChanged += new MovieTickets.MovieChangedHandler(NewPurchase);
 }