Esempio n. 1
0
        public void Initialize()
        {
            var address = new Address("Tel-Aviv", 12345);

            var yossi = new Person("Yossi", 50, address);
            var sima = new Person("Sima", 30, address);

            yossi.Spouse = sima;
            sima.Spouse = yossi;

            Persons.Add(yossi);
            Persons.Add(sima);
        }
Esempio n. 2
0
 public Person(string name, int age, Address address)
 {
     Name = name;
     Age = age;
     Address = address;
 }