示例#1
0
        //Called by the client / tester
        static public IPromotionMatcher getPromotionObj(string site)
        {
            IPromotionMatcher objPromotion = null;

            //-------------------------------------------------------------------------------------------------------------
            //NOT: A Collection(array, link list, hashtable) can be added to store the list of the online promotion sites
            //--------------------------------------------------------------------------------------------------------------
            switch (site)
            {
            case "Oz Winner":
                objPromotion = new OzWinner();
                break;

            case "Surface Promotion":
                objPromotion = new SurfacePromotion();
                break;

            case "Hopeless Online Promotion":
                objPromotion = new HopelessOnlinePromotion();
                break;

            default:
                return(objPromotion);
            }
            return(objPromotion);
        }
        //Called by the client / tester
        public static IPromotionMatcher getPromotionObj(string site)
        {
            IPromotionMatcher objPromotion = null;
            //-------------------------------------------------------------------------------------------------------------
            //NOT: A Collection(array, link list, hashtable) can be added to store the list of the online promotion sites
            //--------------------------------------------------------------------------------------------------------------
            switch (site)
            {
                case "Oz Winner":
                    objPromotion = new OzWinner();
                    break;
                case "Surface Promotion":
                    objPromotion = new SurfacePromotion();
                    break;
                case "Hopeless Online Promotion":
                    objPromotion = new HopelessOnlinePromotion();
                    break;
                default:
                    return objPromotion;

            }
            return objPromotion;
        }