public LiveBrewCommandDispatcher GetLiveBrewCommandDispatcher(string fieldSection)
        {
            switch (fieldSection)
            {
            case "Weigh bin Mash Copper":
            case "MASH COPPER":
                liveBrewCommandDispatcher = MashCopperCommandDispatcher.GetInstance();
                break;

            case "WEIGHBIN MASHTUN":
            case "MASH TUN":
                liveBrewCommandDispatcher = MashTunCommandDispatcher.GetInstance();
                break;

            case "MASH FILTER":
                liveBrewCommandDispatcher = MashFilterCommandDispatcher.GetInstance();
                break;

            case "HOLDING VESSEL":
            case "HOLDING VESSEL TO WORT COPPER":
                liveBrewCommandDispatcher = HoldingVesselCommandDispatcher.GetInstance();
                break;

            case "WORT COPPER":
                liveBrewCommandDispatcher = WortCopperCommandDispatcher.GetInstance();
                break;

            case "WHIRLPOOL":
                liveBrewCommandDispatcher = WhirlpoolCommandDispatcher.GetInstance();
                break;
            }

            return(liveBrewCommandDispatcher);
        }
Exemplo n.º 2
0
        //lazy construction of instance
        public static MashTunCommandDispatcher GetInstance()
        {
            if (_uniqueInstance == null)
            {
                _uniqueInstance = new MashTunCommandDispatcher();
            }

            return(_uniqueInstance);
        }