Пример #1
0
        public override int GetHashCode()
        {
            int hash = 1;

            if (Name.Length != 0)
            {
                hash ^= Name.GetHashCode();
            }
            if (Tel.Length != 0)
            {
                hash ^= Tel.GetHashCode();
            }
            if (Addr.Length != 0)
            {
                hash ^= Addr.GetHashCode();
            }
            if (Postcode.Length != 0)
            {
                hash ^= Postcode.GetHashCode();
            }
            if (_unknownFields != null)
            {
                hash ^= _unknownFields.GetHashCode();
            }
            return(hash);
        }
Пример #2
0
 public override int GetHashCode()
 {
     unchecked
     {
         var hashCode = (Gcp != null ? Gcp.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ (Name != null ? Name.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ (Addr2 != null ? Addr2.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ (Addr3 != null ? Addr3.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ (Addr4 != null ? Addr4.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ (PostalCode != null ? PostalCode.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ (City != null ? City.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ (Tel != null ? Tel.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ (Mail != null ? Mail.GetHashCode() : 0);
         return(hashCode);
     }
 }
Пример #3
0
 /// <summary>
 /// Serves as a hash function for a particular type.
 /// </summary>
 /// <returns>
 /// A hash code for the current <see cref="T:System.Object"/>.
 /// </returns>
 public override int GetHashCode()
 {
     unchecked
     {
         var hashCode = Fn?.GetHashCode() ?? 0;
         hashCode = (hashCode * 397) ^ (Email?.GetHashCode() ?? 0);
         hashCode = (hashCode * 397) ^ (Url?.GetHashCode() ?? 0);
         hashCode = (hashCode * 397) ^ (Org?.GetHashCode() ?? 0);
         hashCode = (hashCode * 397) ^ (Adr?.GetHashCode() ?? 0);
         hashCode = (hashCode * 397) ^ (Tel?.GetHashCode() ?? 0);
         hashCode = (hashCode * 397) ^ (XTwitter?.GetHashCode() ?? 0);
         hashCode = (hashCode * 397) ^ (XGithub?.GetHashCode() ?? 0);
         hashCode = (hashCode * 397) ^ (Photo?.GetHashCode() ?? 0);
         hashCode = (hashCode * 397) ^ (VCard?.GetHashCode() ?? 0);
         return(hashCode);
     }
 }
Пример #4
0
 /// <summary>
 /// Serves as a hash function for a particular type.
 /// </summary>
 /// <returns>
 /// A hash code for the current <see cref="T:System.Object"/>.
 /// </returns>
 public override int GetHashCode()
 {
     unchecked
     {
         var hashCode = (Fn != null ? Fn.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ (Email != null ? Email.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ (Url != null ? Url.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ (Org != null ? Org.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ (Adr != null ? Adr.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ (Tel != null ? Tel.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ (XTwitter != null ? XTwitter.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ (XGithub != null ? XGithub.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ (Photo != null ? Photo.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ (VCard != null ? VCard.GetHashCode() : 0);
         return(hashCode);
     }
 }