예제 #1
0
 public void MergeFrom(TaskStatus other)
 {
     if (other == null)
     {
         return;
     }
     if (other.AttemptDispatchCount != 0)
     {
         AttemptDispatchCount = other.AttemptDispatchCount;
     }
     if (other.AttemptResponseCount != 0)
     {
         AttemptResponseCount = other.AttemptResponseCount;
     }
     if (other.firstAttemptStatus_ != null)
     {
         if (firstAttemptStatus_ == null)
         {
             firstAttemptStatus_ = new global::Google.Cloud.Tasks.V2Beta2.AttemptStatus();
         }
         FirstAttemptStatus.MergeFrom(other.FirstAttemptStatus);
     }
     if (other.lastAttemptStatus_ != null)
     {
         if (lastAttemptStatus_ == null)
         {
             lastAttemptStatus_ = new global::Google.Cloud.Tasks.V2Beta2.AttemptStatus();
         }
         LastAttemptStatus.MergeFrom(other.LastAttemptStatus);
     }
     _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields);
 }
예제 #2
0
        public override int GetHashCode()
        {
            int hash = 1;

            if (AttemptDispatchCount != 0)
            {
                hash ^= AttemptDispatchCount.GetHashCode();
            }
            if (AttemptResponseCount != 0)
            {
                hash ^= AttemptResponseCount.GetHashCode();
            }
            if (firstAttemptStatus_ != null)
            {
                hash ^= FirstAttemptStatus.GetHashCode();
            }
            if (lastAttemptStatus_ != null)
            {
                hash ^= LastAttemptStatus.GetHashCode();
            }
            if (_unknownFields != null)
            {
                hash ^= _unknownFields.GetHashCode();
            }
            return(hash);
        }