Esempio n. 1
0
        static void Main(string[] args)
        {
            var vet = new Vet();
            var mgr = new Manager();
            var zoo = new Zoo {
                mgr = mgr, vet = vet
            };
            AnimalFactory <Horse> factory = new AnimalFactory <Horse>();
            var horse = factory.Create("Milly", zoo);

            horse.Hungry();
            vet.BeginVaccination();
        }