/// <summary> /// Returns true if OrgApacheJackrabbitOakSecurityAuthenticationTokenTokenConfiguraProperties instances are equal /// </summary> /// <param name="other">Instance of OrgApacheJackrabbitOakSecurityAuthenticationTokenTokenConfiguraProperties to be compared</param> /// <returns>Boolean</returns> public bool Equals(OrgApacheJackrabbitOakSecurityAuthenticationTokenTokenConfiguraProperties other) { if (other is null) { return(false); } if (ReferenceEquals(this, other)) { return(true); } return (( TokenExpiration == other.TokenExpiration || TokenExpiration != null && TokenExpiration.Equals(other.TokenExpiration) ) && ( TokenLength == other.TokenLength || TokenLength != null && TokenLength.Equals(other.TokenLength) ) && ( TokenRefresh == other.TokenRefresh || TokenRefresh != null && TokenRefresh.Equals(other.TokenRefresh) ) && ( TokenCleanupThreshold == other.TokenCleanupThreshold || TokenCleanupThreshold != null && TokenCleanupThreshold.Equals(other.TokenCleanupThreshold) ) && ( PasswordHashAlgorithm == other.PasswordHashAlgorithm || PasswordHashAlgorithm != null && PasswordHashAlgorithm.Equals(other.PasswordHashAlgorithm) ) && ( PasswordHashIterations == other.PasswordHashIterations || PasswordHashIterations != null && PasswordHashIterations.Equals(other.PasswordHashIterations) ) && ( PasswordSaltSize == other.PasswordSaltSize || PasswordSaltSize != null && PasswordSaltSize.Equals(other.PasswordSaltSize) )); }
/// <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 :) if (TokenExpiration != null) { hashCode = hashCode * 59 + TokenExpiration.GetHashCode(); } if (TokenLength != null) { hashCode = hashCode * 59 + TokenLength.GetHashCode(); } if (TokenRefresh != null) { hashCode = hashCode * 59 + TokenRefresh.GetHashCode(); } if (TokenCleanupThreshold != null) { hashCode = hashCode * 59 + TokenCleanupThreshold.GetHashCode(); } if (PasswordHashAlgorithm != null) { hashCode = hashCode * 59 + PasswordHashAlgorithm.GetHashCode(); } if (PasswordHashIterations != null) { hashCode = hashCode * 59 + PasswordHashIterations.GetHashCode(); } if (PasswordSaltSize != null) { hashCode = hashCode * 59 + PasswordSaltSize.GetHashCode(); } return(hashCode); } }