Example #1
0
 /// <summary>
 /// Instantiate a cooker
 /// </summary>
 /// <param name="toolsStorage"></param>
 public Cooker(int id, Washer washer, Oven oven)
 {
     this.Id             = id;
     this.ToolsStorage   = ToolsManager.GetInstance();
     this.DevicesStorage = DevicesManager.GetInstance();
     this.WasherEngine   = washer;
     this.OvenCook       = oven;
     this.IsAvailable    = true;
 }
Example #2
0
        public CookChief(int cookers, Washer washer, Counter counterplate = null)
        {
            this.CounterPlate = counterplate;
            this.Cookers      = new List <Cooker>();
            washer.StartWorking().Start();

            Oven oven = new Oven();

            for (int i = 0; i <= cookers; i++)
            {
                this.Cookers.Add(new Cooker(i, washer, oven));
            }
        }