コード例 #1
0
        static void Main(string[] args)
        {
            PizzaStore nyPizzaStore = new NYPizzaStore();

            nyPizzaStore.OrderPizza("cheese");
            nyPizzaStore.OrderPizza("clam");
            nyPizzaStore.OrderPizza("pepperoni");

            Console.ReadLine();
        }
コード例 #2
0
        static void Main(string[] args)
        {
            PizzaStore nyStore      = new NYPizzaStore();
            PizzaStore chicagoStore = new ChicagoPizzaStore();

            Pizza pizza = nyStore.OrderPizza("cheese");

            Console.WriteLine("Ethan ordered a " + pizza.GetName() + "\n");

            pizza = chicagoStore.OrderPizza("cheese");
            Console.WriteLine("Jole ordered a " + pizza.GetName() + "\n");

            Console.Read();
        }
コード例 #3
0
ファイル: Program.cs プロジェクト: usamanoman/Design-Patterns
 static void Main(string[] args)
 {
     PizzaStore ps = new NYPizzaStore();
     ps.orderPizza("spice");
 }