/// <summary> /// Gets the hash code /// </summary> /// <returns>Hash code</returns> public override int GetHashCode() { unchecked // Overflow is fine, just wrap { var hashCode = 41; // Suitable nullity checks etc, of course :) hashCode = hashCode * 59 + IdPlace.GetHashCode(); if (ZipCode != null) { hashCode = hashCode * 59 + ZipCode.GetHashCode(); } if (_Place != null) { hashCode = hashCode * 59 + _Place.GetHashCode(); } if (Canton != null) { hashCode = hashCode * 59 + Canton.GetHashCode(); } if (CantonAbb != null) { hashCode = hashCode * 59 + CantonAbb.GetHashCode(); } return(hashCode); } }
public override int GetHashCode() { var hashCode = 875105097; hashCode = hashCode * -1521134295 + EqualityComparer <string> .Default.GetHashCode(Name); hashCode = hashCode * -1521134295 + IdPlace.GetHashCode(); return(hashCode); }