Ejemplo n.º 1
0
        public void MergeFrom(CampaignBidModifier other)
        {
            if (other == null)
            {
                return;
            }
            if (other.ResourceName.Length != 0)
            {
                ResourceName = other.ResourceName;
            }
            if (other.HasCampaign)
            {
                Campaign = other.Campaign;
            }
            if (other.HasCriterionId)
            {
                CriterionId = other.CriterionId;
            }
            if (other.HasBidModifier)
            {
                BidModifier = other.BidModifier;
            }
            switch (other.CriterionCase)
            {
            case CriterionOneofCase.InteractionType:
                if (InteractionType == null)
                {
                    InteractionType = new global::Google.Ads.GoogleAds.V8.Common.InteractionTypeInfo();
                }
                InteractionType.MergeFrom(other.InteractionType);
                break;
            }

            _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields);
        }
Ejemplo n.º 2
0
        public void MergeFrom(pb::CodedInputStream input)
        {
    #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
            input.ReadRawMessage(this);
    #else
            uint tag;
            while ((tag = input.ReadTag()) != 0)
            {
                switch (tag)
                {
                default:
                    _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input);
                    break;

                case 10: {
                    ResourceName = input.ReadString();
                    break;
                }

                case 42: {
                    global::Google.Ads.GoogleAds.V8.Common.InteractionTypeInfo subBuilder = new global::Google.Ads.GoogleAds.V8.Common.InteractionTypeInfo();
                    if (criterionCase_ == CriterionOneofCase.InteractionType)
                    {
                        subBuilder.MergeFrom(InteractionType);
                    }
                    input.ReadMessage(subBuilder);
                    InteractionType = subBuilder;
                    break;
                }

                case 50: {
                    Campaign = input.ReadString();
                    break;
                }

                case 56: {
                    CriterionId = input.ReadInt64();
                    break;
                }

                case 65: {
                    BidModifier = input.ReadDouble();
                    break;
                }
                }
            }
    #endif
        }
Ejemplo n.º 3
0
        void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input)
        {
            uint tag;

            while ((tag = input.ReadTag()) != 0)
            {
                switch (tag)
                {
                default:
                    _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, ref input);
                    break;

                case 10: {
                    ResourceName = input.ReadString();
                    break;
                }

                case 42: {
                    global::Google.Ads.GoogleAds.V8.Common.InteractionTypeInfo subBuilder = new global::Google.Ads.GoogleAds.V8.Common.InteractionTypeInfo();
                    if (criterionCase_ == CriterionOneofCase.InteractionType)
                    {
                        subBuilder.MergeFrom(InteractionType);
                    }
                    input.ReadMessage(subBuilder);
                    InteractionType = subBuilder;
                    break;
                }

                case 50: {
                    Campaign = input.ReadString();
                    break;
                }

                case 56: {
                    CriterionId = input.ReadInt64();
                    break;
                }

                case 65: {
                    BidModifier = input.ReadDouble();
                    break;
                }
                }
            }
        }