static void AtCafetearea(IEat worker) { Console.WriteLine("At Cafeate Area!"); try { worker.StartEat(); worker.StopEat(); } catch (Exception e) { Console.WriteLine("Message:" + e.Message); } }
static void AtTheCafeteria(IEat worker) { Console.WriteLine("at the cafeteria"); worker.StartEat(); worker.StopEat(); }
private static void AtTheCafeteria(IEat eat) { Console.WriteLine("Inside Cafeteria"); eat.StartEat(); eat.StopEat(); }