コード例 #1
0
        public override int GetHashCode()
        {
            int hash = 1;

            if (Name.Length != 0)
            {
                hash ^= Name.GetHashCode();
            }
            hash ^= Marks.GetHashCode();
            if (CanonicalName.Length != 0)
            {
                hash ^= CanonicalName.GetHashCode();
            }
            if (_unknownFields != null)
            {
                hash ^= _unknownFields.GetHashCode();
            }
            return(hash);
        }
コード例 #2
0
 public override int GetHashCode()
 {
     return(base.GetHashCode() + Name.GetHashCode() + Teacher.GetHashCode() + Marks.GetHashCode());
 }