示例#1
0
        static void Main(string[] args)
        {
            ISweepstakesManager manager       = SweepstakesFactory.ChooseYourSweepstakesManagerStyle();
            MarketingFirm       marketingFirm = new MarketingFirm(manager);

            marketingFirm.CreateSweepstakes();
            marketingFirm.RunSweepstakes();
        }
示例#2
0
        public void CreateMarketingFirmWithManager()
        {
            string              sweepstakesName    = Userinterface.GetNewSweepstakesName();
            string              userInput          = Userinterface.ChooseStackOrQueue();
            SweepstakesFactory  factory            = new SweepstakesFactory();
            ISweepstakesManager sweepstakesManager = factory.CreateFactory(userInput);
            MarketingFirm       marketingFirm      = new MarketingFirm(sweepstakesManager, sweepstakesName);

            marketingFirm.CreateSweepStakes();
        }
示例#3
0
        static void Main(string[] args)
        {
            //Contestant alex = new Contestant();

            //alex.email = "*****@*****.**";
            //alex.isWinner = true;
            //alex.NotifyContestant();



            SweepstakesFactory  factory = new SweepstakesFactory();
            string              style   = UI.GetManagerStyle();
            ISweepstakesManager manager = factory.CreateSweepstakesManager(style);
            MarketingFirm       firm    = new MarketingFirm(manager);

            firm.Menu();
        }