Esempio n. 1
0
 public Country GetCountryRefInsideList(Country toFind, ObservableCollection <Country> countries)
 {
     foreach (Country country in countries)
     {
         if (toFind.Equals(country))
         {
             return(country);
         }
     }
     return(null);
 }
Esempio n. 2
0
 public bool Equals(Address other)
 {
     if (!Country.Equals(other.Country))
     {
         return(false);
     }
     if (!Town.Equals(other.Town))
     {
         return(false);
     }
     if (!Street.Equals(other.Street))
     {
         return(false);
     }
     if (!Building.Equals(other.Building))
     {
         return(false);
     }
     return(true);
 }