/// <summary> /// 用唯一值实现GetHashCode /// </summary> public override int GetHashCode() { int hash = 57; hash = 27 * hash * DisplayMember.GetHashCode(); return(hash); }
public override int GetHashCode() { unchecked { return(((DisplayMember != null ? DisplayMember.GetHashCode() : 0) * 397) ^ (ValueMember != null ? ValueMember.GetHashCode() : 0)); } }
public override int GetHashCode() { int multiplier = 23; if (hashCode == 0) { int code = 133; code = multiplier * code + DisplayMember.GetHashCode(); code = multiplier * code + ValueMember.GetHashCode(); hashCode = code; } return(hashCode); }