示例#1
0
        public override void WriteTo(XElement xE)
        {
            base.WriteTo(xE);
            XmlUtility.SetXsiType(xE, "https://adwords.google.com/api/adwords/cm/v201609", "TargetRoasBiddingScheme");
            XElement xItem = null;

            if (TargetRoas != null)
            {
                xItem = new XElement(XName.Get("targetRoas", "https://adwords.google.com/api/adwords/cm/v201609"));
                xItem.Add(TargetRoas.Value.ToString());
                xE.Add(xItem);
            }
            if (BidCeiling != null)
            {
                xItem = new XElement(XName.Get("bidCeiling", "https://adwords.google.com/api/adwords/cm/v201609"));
                BidCeiling.WriteTo(xItem);
                xE.Add(xItem);
            }
            if (BidFloor != null)
            {
                xItem = new XElement(XName.Get("bidFloor", "https://adwords.google.com/api/adwords/cm/v201609"));
                BidFloor.WriteTo(xItem);
                xE.Add(xItem);
            }
        }
        public override void WriteTo(XElement xE)
        {
            base.WriteTo(xE);
            XmlUtility.SetXsiType(xE, "https://adwords.google.com/api/adwords/cm/v201609", "BudgetOptimizerBiddingScheme");
            XElement xItem = null;

            if (BidCeiling != null)
            {
                xItem = new XElement(XName.Get("bidCeiling", "https://adwords.google.com/api/adwords/cm/v201609"));
                BidCeiling.WriteTo(xItem);
                xE.Add(xItem);
            }
            if (EnhancedCpcEnabled != null)
            {
                xItem = new XElement(XName.Get("enhancedCpcEnabled", "https://adwords.google.com/api/adwords/cm/v201609"));
                xItem.Add(EnhancedCpcEnabled.Value.ToString());
                xE.Add(xItem);
            }
        }
        public override void WriteTo(XElement xE)
        {
            base.WriteTo(xE);
            XmlUtility.SetXsiType(xE, "https://adwords.google.com/api/adwords/cm/v201609", "TargetSpendBiddingScheme");
            XElement xItem = null;

            if (BidCeiling != null)
            {
                xItem = new XElement(XName.Get("bidCeiling", "https://adwords.google.com/api/adwords/cm/v201609"));
                BidCeiling.WriteTo(xItem);
                xE.Add(xItem);
            }
            if (SpendTarget != null)
            {
                xItem = new XElement(XName.Get("spendTarget", "https://adwords.google.com/api/adwords/cm/v201609"));
                SpendTarget.WriteTo(xItem);
                xE.Add(xItem);
            }
        }
示例#4
0
        public override void WriteTo(XElement xE)
        {
            base.WriteTo(xE);
            XmlUtility.SetXsiType(xE, "https://adwords.google.com/api/adwords/cm/v201609", "PageOnePromotedBiddingScheme");
            XElement xItem = null;

            if (StrategyGoal != null)
            {
                xItem = new XElement(XName.Get("strategyGoal", "https://adwords.google.com/api/adwords/cm/v201609"));
                xItem.Add(StrategyGoal.Value.ToXmlValue());
                xE.Add(xItem);
            }
            if (BidCeiling != null)
            {
                xItem = new XElement(XName.Get("bidCeiling", "https://adwords.google.com/api/adwords/cm/v201609"));
                BidCeiling.WriteTo(xItem);
                xE.Add(xItem);
            }
            if (BidModifier != null)
            {
                xItem = new XElement(XName.Get("bidModifier", "https://adwords.google.com/api/adwords/cm/v201609"));
                xItem.Add(BidModifier.Value.ToString());
                xE.Add(xItem);
            }
            if (BidChangesForRaisesOnly != null)
            {
                xItem = new XElement(XName.Get("bidChangesForRaisesOnly", "https://adwords.google.com/api/adwords/cm/v201609"));
                xItem.Add(BidChangesForRaisesOnly.Value.ToString());
                xE.Add(xItem);
            }
            if (RaiseBidWhenBudgetConstrained != null)
            {
                xItem = new XElement(XName.Get("raiseBidWhenBudgetConstrained", "https://adwords.google.com/api/adwords/cm/v201609"));
                xItem.Add(RaiseBidWhenBudgetConstrained.Value.ToString());
                xE.Add(xItem);
            }
            if (RaiseBidWhenLowQualityScore != null)
            {
                xItem = new XElement(XName.Get("raiseBidWhenLowQualityScore", "https://adwords.google.com/api/adwords/cm/v201609"));
                xItem.Add(RaiseBidWhenLowQualityScore.Value.ToString());
                xE.Add(xItem);
            }
        }