public override int GetHashCode() { unchecked { var result = NamedTupleCommon.DefaultHashCode; result = (result << 5) + result ^ (Id.GetHashCode()); result = (result << 5) + result ^ (CareOf != null ? CareOf.GetHashCode() : NamedTupleCommon.DefaultHashCode); result = (result << 5) + result ^ (Address1 != null ? Address1.GetHashCode() : NamedTupleCommon.DefaultHashCode); result = (result << 5) + result ^ (Address2 != null ? Address2.GetHashCode() : NamedTupleCommon.DefaultHashCode); result = (result << 5) + result ^ (Address3 != null ? Address3.GetHashCode() : NamedTupleCommon.DefaultHashCode); result = (result << 5) + result ^ (Address4 != null ? Address4.GetHashCode() : NamedTupleCommon.DefaultHashCode); result = (result << 5) + result ^ (City != null ? City.GetHashCode() : NamedTupleCommon.DefaultHashCode); result = (result << 5) + result ^ (Zip != null ? Zip.GetHashCode() : NamedTupleCommon.DefaultHashCode); result = (result << 5) + result ^ (County != null ? County.GetHashCode() : NamedTupleCommon.DefaultHashCode); result = (result << 5) + result ^ (Country != null ? Country.GetHashCode() : NamedTupleCommon.DefaultHashCode); return(result); } }
public override int GetHashCode() { unchecked { var hashCode = Company != null?Company.GetHashCode() : 0; hashCode = (hashCode * 397) ^ (Address1 != null ? Address1.GetHashCode() : 0); hashCode = (hashCode * 397) ^ (Address2 != null ? Address2.GetHashCode() : 0); hashCode = (hashCode * 397) ^ (Address3 != null ? Address3.GetHashCode() : 0); hashCode = (hashCode * 397) ^ (Address4 != null ? Address4.GetHashCode() : 0); hashCode = (hashCode * 397) ^ (Address5 != null ? Address5.GetHashCode() : 0); hashCode = (hashCode * 397) ^ (Town != null ? Town.GetHashCode() : 0); hashCode = (hashCode * 397) ^ (County != null ? County.GetHashCode() : 0); hashCode = (hashCode * 397) ^ (Postcode != null ? Postcode.GetHashCode() : 0); hashCode = (hashCode * 397) ^ (Country != null ? Country.GetHashCode() : 0); return(hashCode); } }