示例#1
0
        static void Main(string[] args)
        {
            Factory factory1 = new NorthFactory();
            var     fruit    = factory1.CreateFruit();

            Console.WriteLine(fruit.GetFruitName());
            Console.ReadKey();
        }
示例#2
0
        static void Main(string[] args)
        {
            Factory factory1 = new NorthFactory();
           var fruit=  factory1.CreateFruit();
           Console.WriteLine(fruit.GetFruitName());
           Console.ReadKey();

        }