public override int GetHashCode() { var hash = 3; hash = (hash * 2) + EnableLdapAuthentication.GetHashCode(); hash = (hash * 2) + StartTls.GetHashCode(); hash = (hash * 2) + Server.GetHashCode(); hash = (hash * 2) + UserDN.GetHashCode(); hash = (hash * 2) + PortNumber.GetHashCode(); hash = (hash * 2) + UserFilter.GetHashCode(); hash = (hash * 2) + LoginAttribute.GetHashCode(); hash = (hash * 2) + FirstNameAttribute.GetHashCode(); hash = (hash * 2) + SecondNameAttribute.GetHashCode(); hash = (hash * 2) + MailAttribute.GetHashCode(); hash = (hash * 2) + TitleAttribute.GetHashCode(); hash = (hash * 2) + MobilePhoneAttribute.GetHashCode(); hash = (hash * 2) + LocationAttribute.GetHashCode(); hash = (hash * 2) + GroupMembership.GetHashCode(); hash = (hash * 2) + GroupDN.GetHashCode(); hash = (hash * 2) + GroupNameAttribute.GetHashCode(); hash = (hash * 2) + GroupFilter.GetHashCode(); hash = (hash * 2) + UserAttribute.GetHashCode(); hash = (hash * 2) + GroupAttribute.GetHashCode(); hash = (hash * 2) + Authentication.GetHashCode(); hash = (hash * 2) + Login.GetHashCode(); return(hash); }
public override int GetHashCode() { var hash = 3; hash = (hash * 2) + EnableLdapAuthentication.GetHashCode(); hash = (hash * 2) + StartTls.GetHashCode(); hash = (hash * 2) + Ssl.GetHashCode(); hash = (hash * 2) + SendWelcomeEmail.GetHashCode(); hash = (hash * 2) + Server.GetHashCode(); hash = (hash * 2) + UserDN.GetHashCode(); hash = (hash * 2) + PortNumber.GetHashCode(); hash = (hash * 2) + UserFilter.GetHashCode(); hash = (hash * 2) + LoginAttribute.GetHashCode(); hash = (hash * 2) + GroupMembership.GetHashCode(); hash = (hash * 2) + GroupDN.GetHashCode(); hash = (hash * 2) + GroupNameAttribute.GetHashCode(); hash = (hash * 2) + GroupFilter.GetHashCode(); hash = (hash * 2) + UserAttribute.GetHashCode(); hash = (hash * 2) + GroupAttribute.GetHashCode(); hash = (hash * 2) + Authentication.GetHashCode(); hash = (hash * 2) + Login.GetHashCode(); foreach (var pair in LdapMapping) { hash = (hash * 2) + pair.Value.GetHashCode(); } foreach (var pair in AccessRights) { hash = (hash * 2) + pair.Value.GetHashCode(); } return(hash); }
public override int GetHashCode() { int hash = 1; if (property_ != null) { hash ^= Property.GetHashCode(); } if (PostmarkEmailSenderAddress.Length != 0) { hash ^= PostmarkEmailSenderAddress.GetHashCode(); } if (PostmarkApiKey.Length != 0) { hash ^= PostmarkApiKey.GetHashCode(); } if (DisableAllCorrespondence != false) { hash ^= DisableAllCorrespondence.GetHashCode(); } if (SmtpEmailSenderAddress.Length != 0) { hash ^= SmtpEmailSenderAddress.GetHashCode(); } if (PortNumber.Length != 0) { hash ^= PortNumber.GetHashCode(); } if (IsPostmark != false) { hash ^= IsPostmark.GetHashCode(); } if (ExchangeEmailSenderAddress.Length != 0) { hash ^= ExchangeEmailSenderAddress.GetHashCode(); } if (ExchangeApiKey.Length != 0) { hash ^= ExchangeApiKey.GetHashCode(); } return(hash); }
public override int GetHashCode() { unchecked { // Choose large primes to avoid hashing collisions const int HashingBase = (int)2166136261; const int HashingMultiplier = 16777619; int hash = HashingBase; hash = (hash * HashingMultiplier) ^ (!object.ReferenceEquals(null, Hostname) ? Hostname.GetHashCode() : 0); hash = (hash * HashingMultiplier) ^ (!object.ReferenceEquals(null, PortNumber) ? PortNumber.GetHashCode() : 0); hash = (hash * HashingMultiplier) ^ (!object.ReferenceEquals(null, MacAddress) ? MacAddress.GetHashCode() : 0); return(hash); } }