Пример #1
0
        public static void Main(string[] args)
        {
            TakimconCreteAggregate TakimCollection = new TakimconCreteAggregate();

            TakimCollection.Add(new Takim {
                TakimAdi = "Şalvar spor", Puan = 55
            });
            TakimCollection.Add(new Takim {
                TakimAdi = "Real Madrid", Puan = 9
            });
            TakimCollection.Add(new Takim {
                TakimAdi = "Barcelona", Puan = 10
            });

            ITakimIterator itr = TakimCollection.GetIterator();

            while (itr.IsDone())
            {
                Console.WriteLine("{0}:{1}", itr.CurrentItem().TakimAdi, itr.CurrentItem().Puan);
                itr.Next();
            }

            Console.ReadKey();
        }
Пример #2
0
 public TakimConcreteIterator(TakimconCreteAggregate ColTakim)
 {
     this.CollectionTakim = ColTakim;
 }