示例#1
0
        public override int GetHashCode()
        {
            int hash = 1;

            if (Signature.Length != 0)
            {
                hash ^= Signature.GetHashCode();
            }
            if (SenderID.Length != 0)
            {
                hash ^= SenderID.GetHashCode();
            }
            if (contentCase_ == ContentOneofCase.Message)
            {
                hash ^= Message.GetHashCode();
            }
            if (contentCase_ == ContentOneofCase.Request)
            {
                hash ^= Request.GetHashCode();
            }
            if (contentCase_ == ContentOneofCase.Response)
            {
                hash ^= Response.GetHashCode();
            }
            hash ^= (int)contentCase_;
            if (_unknownFields != null)
            {
                hash ^= _unknownFields.GetHashCode();
            }
            return(hash);
        }
示例#2
0
 public override int GetHashCode()
 {
     unchecked
     {
         int result = (SenderID != null ? SenderID.GetHashCode() : 0);
         result = (result * 397) ^ (ReceiverID != null ? ReceiverID.GetHashCode() : 0);
         result = (result * 397) ^ (MessageID != null ? MessageID.GetHashCode() : 0);
         result = (result * 397) ^ (Body != null ? Body.GetHashCode() : 0);
         return(result);
     }
 }
示例#3
0
 public override int GetHashCode()
 {
     return(SenderID.GetHashCode() + ReceiverID.GetHashCode() + Op.GetHashCode());
 }