示例#1
0
        /// <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 + HttpStatus.GetHashCode();

                hashCode = hashCode * 59 + ErrorCode.GetHashCode();
                if (Description != null)
                {
                    hashCode = hashCode * 59 + Description.GetHashCode();
                }
                if (DocumentationLink != null)
                {
                    hashCode = hashCode * 59 + DocumentationLink.GetHashCode();
                }
                if (AdditionalInfo != null)
                {
                    hashCode = hashCode * 59 + AdditionalInfo.GetHashCode();
                }
                return(hashCode);
            }
        }