Exemple #1
0
        public void MergeFrom(OperationMetadataV1 other)
        {
            if (other == null)
            {
                return;
            }
            if (other.Method.Length != 0)
            {
                Method = other.Method;
            }
            if (other.insertTime_ != null)
            {
                if (insertTime_ == null)
                {
                    InsertTime = new global::Google.Protobuf.WellKnownTypes.Timestamp();
                }
                InsertTime.MergeFrom(other.InsertTime);
            }
            if (other.endTime_ != null)
            {
                if (endTime_ == null)
                {
                    EndTime = new global::Google.Protobuf.WellKnownTypes.Timestamp();
                }
                EndTime.MergeFrom(other.EndTime);
            }
            if (other.User.Length != 0)
            {
                User = other.User;
            }
            if (other.Target.Length != 0)
            {
                Target = other.Target;
            }
            if (other.EphemeralMessage.Length != 0)
            {
                EphemeralMessage = other.EphemeralMessage;
            }
            warning_.Add(other.warning_);
            switch (other.MethodMetadataCase)
            {
            case MethodMetadataOneofCase.CreateVersionMetadata:
                if (CreateVersionMetadata == null)
                {
                    CreateVersionMetadata = new global::Google.Cloud.AppEngine.V1.CreateVersionMetadataV1();
                }
                CreateVersionMetadata.MergeFrom(other.CreateVersionMetadata);
                break;
            }

            _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields);
        }
Exemple #2
0
        public override int GetHashCode()
        {
            int hash = 1;

            if (Method.Length != 0)
            {
                hash ^= Method.GetHashCode();
            }
            if (insertTime_ != null)
            {
                hash ^= InsertTime.GetHashCode();
            }
            if (endTime_ != null)
            {
                hash ^= EndTime.GetHashCode();
            }
            if (User.Length != 0)
            {
                hash ^= User.GetHashCode();
            }
            if (Target.Length != 0)
            {
                hash ^= Target.GetHashCode();
            }
            if (EphemeralMessage.Length != 0)
            {
                hash ^= EphemeralMessage.GetHashCode();
            }
            hash ^= warning_.GetHashCode();
            if (methodMetadataCase_ == MethodMetadataOneofCase.CreateVersionMetadata)
            {
                hash ^= CreateVersionMetadata.GetHashCode();
            }
            hash ^= (int)methodMetadataCase_;
            if (_unknownFields != null)
            {
                hash ^= _unknownFields.GetHashCode();
            }
            return(hash);
        }