public void registerObserver(Observer observer)
        {
            var enumerator = quackers.GetEnumerator();

            while (enumerator.MoveNext())
            {
                Quackable duck = enumerator.Current;
                duck.registerObserver(observer);
            }
        }
Exemple #2
0
    public void registerObserver(Observer observer)
    {
        //foarte important as parcurgem si sa face inregistrare la fiecare in parte
        IEnumerator <Quackable> enumerable = quackers.GetEnumerator();

        while (enumerable.MoveNext())
        {
            Quackable quacker = enumerable.Current;
            quacker.registerObserver(observer);
        }
    }
Exemple #3
0
 public void registerObserver(Observer observer)
 {
     duck.registerObserver(observer);
 }
Exemple #4
0
 public void registerObserver(Observer observer)
 {
     duck.registerObserver(observer); //important , se ajunge mai intai la decorator si dupa la obiectul efectiv
 }