Exemplo n.º 1
0
        public Brew(string startDate, string brandName, string brewNumber)
        {
            _startDate  = startDate;
            _startTime  = "";
            _brandName  = brandName;
            _brewNumber = brewNumber;

            //Setup processEquipmentParameters
            processEquipmentParameters.Add(ProcessEquipment.MashCopper, new Dictionary <string, string>());
            processEquipmentParameters.Add(ProcessEquipment.MashTun, new Dictionary <string, string>());
            processEquipmentParameters.Add(ProcessEquipment.MashFilter, new Dictionary <string, string>());
            processEquipmentParameters.Add(ProcessEquipment.HoldingVessel, new Dictionary <string, string>());
            processEquipmentParameters.Add(ProcessEquipment.WortCopper, new Dictionary <string, string>());
            processEquipmentParameters.Add(ProcessEquipment.Whirlpool, new Dictionary <string, string>());

            //Setup states
            _idleState      = new BrewIdleState();
            _inProcessState = new BrewInProcessState();
            _completedState = new BrewCompletedState();

            CurrentState = _idleState;
        }
Exemplo n.º 2
0
 //Methods
 public void SetState(IBrewState newState)
 {
     CurrentState = newState;
     PrintCurrentState();
 }