Example #1
0
 /// <summary>
 /// Sets the InvoiceData property.
 /// </summary>
 /// <param name="invoiceData">InvoiceData property.</param>
 /// <returns>this instance.</returns>
 public OrderItem WithInvoiceData(InvoiceData invoiceData)
 {
     this._invoiceData = invoiceData;
     return(this);
 }
Example #2
0
        /// <summary>
        /// XML fragment representation of this object
        /// </summary>
        /// <returns>XML fragment for this object.</returns>
        /// <remarks>
        /// Name for outer tag expected to be set by calling method.
        /// This fragment returns inner properties representation only
        /// </remarks>


        protected internal String ToXMLFragment()
        {
            StringBuilder xml = new StringBuilder();

            if (IsSetASIN())
            {
                xml.Append("<ASIN>");
                xml.Append(EscapeXML(this.ASIN));
                xml.Append("</ASIN>");
            }
            if (IsSetSellerSKU())
            {
                xml.Append("<SellerSKU>");
                xml.Append(EscapeXML(this.SellerSKU));
                xml.Append("</SellerSKU>");
            }
            if (IsSetOrderItemId())
            {
                xml.Append("<OrderItemId>");
                xml.Append(EscapeXML(this.OrderItemId));
                xml.Append("</OrderItemId>");
            }
            if (IsSetTitle())
            {
                xml.Append("<Title>");
                xml.Append(EscapeXML(this.Title));
                xml.Append("</Title>");
            }
            if (IsSetQuantityOrdered())
            {
                xml.Append("<QuantityOrdered>");
                xml.Append(this.QuantityOrdered);
                xml.Append("</QuantityOrdered>");
            }
            if (IsSetQuantityShipped())
            {
                xml.Append("<QuantityShipped>");
                xml.Append(this.QuantityShipped);
                xml.Append("</QuantityShipped>");
            }
            if (IsSetItemPrice())
            {
                Money itemPriceObj = this.ItemPrice;
                xml.Append("<ItemPrice>");
                xml.Append(itemPriceObj.ToXMLFragment());
                xml.Append("</ItemPrice>");
            }
            if (IsSetShippingPrice())
            {
                Money shippingPriceObj = this.ShippingPrice;
                xml.Append("<ShippingPrice>");
                xml.Append(shippingPriceObj.ToXMLFragment());
                xml.Append("</ShippingPrice>");
            }
            if (IsSetGiftWrapPrice())
            {
                Money giftWrapPriceObj = this.GiftWrapPrice;
                xml.Append("<GiftWrapPrice>");
                xml.Append(giftWrapPriceObj.ToXMLFragment());
                xml.Append("</GiftWrapPrice>");
            }
            if (IsSetItemTax())
            {
                Money itemTaxObj = this.ItemTax;
                xml.Append("<ItemTax>");
                xml.Append(itemTaxObj.ToXMLFragment());
                xml.Append("</ItemTax>");
            }
            if (IsSetShippingTax())
            {
                Money shippingTaxObj = this.ShippingTax;
                xml.Append("<ShippingTax>");
                xml.Append(shippingTaxObj.ToXMLFragment());
                xml.Append("</ShippingTax>");
            }
            if (IsSetGiftWrapTax())
            {
                Money giftWrapTaxObj = this.GiftWrapTax;
                xml.Append("<GiftWrapTax>");
                xml.Append(giftWrapTaxObj.ToXMLFragment());
                xml.Append("</GiftWrapTax>");
            }
            if (IsSetShippingDiscount())
            {
                Money shippingDiscountObj = this.ShippingDiscount;
                xml.Append("<ShippingDiscount>");
                xml.Append(shippingDiscountObj.ToXMLFragment());
                xml.Append("</ShippingDiscount>");
            }
            if (IsSetPromotionDiscount())
            {
                Money promotionDiscountObj = this.PromotionDiscount;
                xml.Append("<PromotionDiscount>");
                xml.Append(promotionDiscountObj.ToXMLFragment());
                xml.Append("</PromotionDiscount>");
            }
            if (IsSetPromotionIds())
            {
                PromotionIdList promotionIdsObj = this.PromotionIds;
                xml.Append("<PromotionIds>");
                xml.Append(promotionIdsObj.ToXMLFragment());
                xml.Append("</PromotionIds>");
            }
            if (IsSetCODFee())
            {
                Money CODFeeObj = this.CODFee;
                xml.Append("<CODFee>");
                xml.Append(CODFeeObj.ToXMLFragment());
                xml.Append("</CODFee>");
            }
            if (IsSetCODFeeDiscount())
            {
                Money CODFeeDiscountObj = this.CODFeeDiscount;
                xml.Append("<CODFeeDiscount>");
                xml.Append(CODFeeDiscountObj.ToXMLFragment());
                xml.Append("</CODFeeDiscount>");
            }
            if (IsSetGiftMessageText())
            {
                xml.Append("<GiftMessageText>");
                xml.Append(EscapeXML(this.GiftMessageText));
                xml.Append("</GiftMessageText>");
            }
            if (IsSetGiftWrapLevel())
            {
                xml.Append("<GiftWrapLevel>");
                xml.Append(EscapeXML(this.GiftWrapLevel));
                xml.Append("</GiftWrapLevel>");
            }
            if (IsSetInvoiceData())
            {
                InvoiceData invoiceDataObj = this.InvoiceData;
                xml.Append("<InvoiceData>");
                xml.Append(invoiceDataObj.ToXMLFragment());
                xml.Append("</InvoiceData>");
            }
            return(xml.ToString());
        }
Example #3
0
 /// <summary>
 /// Sets the InvoiceData property
 /// </summary>
 /// <param name="invoiceData">InvoiceData property</param>
 /// <returns>this instance</returns>
 public OrderItem WithInvoiceData(InvoiceData invoiceData)
 {
     this.invoiceDataField = invoiceData;
     return(this);
 }
Example #4
0
 /// <summary>
 /// Sets the InvoiceData property.
 /// </summary>
 /// <param name="invoiceData">InvoiceData property.</param>
 /// <returns>this instance.</returns>
 public OrderItem WithInvoiceData(InvoiceData invoiceData)
 {
     this._invoiceData = invoiceData;
     return this;
 }
Example #5
0
 public override void ReadFragmentFrom(IMwsReader reader)
 {
     _asin = reader.Read<string>("ASIN");
     _sellerSKU = reader.Read<string>("SellerSKU");
     _orderItemId = reader.Read<string>("OrderItemId");
     _title = reader.Read<string>("Title");
     _quantityOrdered = reader.Read<decimal>("QuantityOrdered");
     _quantityShipped = reader.Read<decimal?>("QuantityShipped");
     _itemPrice = reader.Read<Money>("ItemPrice");
     _shippingPrice = reader.Read<Money>("ShippingPrice");
     _giftWrapPrice = reader.Read<Money>("GiftWrapPrice");
     _itemTax = reader.Read<Money>("ItemTax");
     _shippingTax = reader.Read<Money>("ShippingTax");
     _giftWrapTax = reader.Read<Money>("GiftWrapTax");
     _shippingDiscount = reader.Read<Money>("ShippingDiscount");
     _promotionDiscount = reader.Read<Money>("PromotionDiscount");
     _promotionIds = reader.Read<PromotionIdList>("PromotionIds");
     _codFee = reader.Read<Money>("CODFee");
     _codFeeDiscount = reader.Read<Money>("CODFeeDiscount");
     _giftMessageText = reader.Read<string>("GiftMessageText");
     _giftWrapLevel = reader.Read<string>("GiftWrapLevel");
     _invoiceData = reader.Read<InvoiceData>("InvoiceData");
     _conditionNote = reader.Read<string>("ConditionNote");
     _conditionId = reader.Read<string>("ConditionId");
     _conditionSubtypeId = reader.Read<string>("ConditionSubtypeId");
     _scheduledDeliveryStartDate = reader.Read<string>("ScheduledDeliveryStartDate");
     _scheduledDeliveryEndDate = reader.Read<string>("ScheduledDeliveryEndDate");
 }
 /// <summary>
 /// Sets the InvoiceData property
 /// </summary>
 /// <param name="invoiceData">InvoiceData property</param>
 /// <returns>this instance</returns>
 public OrderItem WithInvoiceData(InvoiceData invoiceData)
 {
     this.invoiceDataField = invoiceData;
     return this;
 }