Example #1
0
        static void Main(string[] args)
        {
            ZooFactory catFactory      = new ZooFactoryB();
            ZooFactory hedgeHogFactory = new ZooFactoryA();

            var cat      = catFactory.FactoryMethod();
            var hedgehog = hedgeHogFactory.FactoryMethod();

            Console.WriteLine(cat.ToString());
            Console.WriteLine(hedgehog.ToString());
        }