Example #1
0
        static void Main(string[] args)
        {
            Menu  menu  = new Menu();
            Order order = menu.CreateOrder();
            Lunch lunch = order.Prepare();

            Console.WriteLine(lunch);
        }
Example #2
0
 public Lunch Prepare()
 {
     Lunch lunch = new Lunch();
     foreach (Product product in products)
     {
         product.Prepare();
         lunch.Add(product);
     }
     return lunch;
 }
Example #3
0
        public Lunch Prepare()
        {
            Lunch lunch = new Lunch();

            foreach (Product product in products)
            {
                product.Prepare();
                lunch.Add(product);
            }
            return(lunch);
        }