Esempio n. 1
0
        static void Main(string[] args)
        {
//            SushiStoreBase store = new XunYangSushiStore();
//            store.OrderSushi("tomato");
//            store = new XiAnSushiStore();
//            store.OrderSushi("ham");

            BuildingMaterialsStoreBase buildingMaterialsStore = new CementStore();

            buildingMaterialsStore.ShowPrice();
            buildingMaterialsStore = new TimberStore();
            buildingMaterialsStore.ShowPrice();
            Console.ReadLine();
        }
Esempio n. 2
0
        static void Main(string[] args)
        {
            //            SushiStoreBase store = new XunYangSushiStore();
            //            store.OrderSushi("tomato");
            //            store = new XiAnSushiStore();
            //            store.OrderSushi("ham");

            BuildingMaterialsStoreBase buildingMaterialsStore=new CementStore();
            buildingMaterialsStore.ShowPrice();
            buildingMaterialsStore=new TimberStore();
            buildingMaterialsStore.ShowPrice();
            Console.ReadLine();
        }