Esempio n. 1
0
 /// <summary>
 /// Initializes a new instance of the <see cref="ProductPatchRequest" /> class.
 /// </summary>
 /// <param name="name">Name of the product.</param>
 /// <param name="description">Description of the product.</param>
 /// <param name="sku">Stock Keeping Unit.</param>
 /// <param name="upc">Universal Product Code.</param>
 /// <param name="ean">European Article Numbering.</param>
 /// <param name="gtin">Global Trade Item Number.</param>
 /// <param name="mpn">Manufacturer Part Number.</param>
 /// <param name="link">Link for the product.</param>
 /// <param name="imageLink">Link for the product image.</param>
 /// <param name="price">Price of the product (default to 0D).</param>
 /// <param name="salePrice">Sale price of the product (default to 0D).</param>
 /// <param name="brand">Brand of the product.</param>
 /// <param name="categories">Array of product categories, using the character &#39;&gt;&#39; as delimiter for the breadcrumb                         syntax.</param>
 /// <param name="relatedProducts">relatedProducts.</param>
 /// <param name="customAttributes">Custom attributes.</param>
 public ProductPatchRequest(string name = default(string), string description = default(string), string sku = default(string), string upc = default(string), string ean = default(string), string gtin = default(string), string mpn = default(string), string link = default(string), string imageLink = default(string), double price = 0D, double salePrice = 0D, string brand = default(string), List <string> categories = default(List <string>), ProductPatchRequestRelatedProducts relatedProducts = default(ProductPatchRequestRelatedProducts), List <ProductCustomAttributes> customAttributes = default(List <ProductCustomAttributes>))
 {
     this.Name        = name;
     this.Description = description;
     this.Sku         = sku;
     this.Upc         = upc;
     this.Ean         = ean;
     this.Gtin        = gtin;
     this.Mpn         = mpn;
     this.Link        = link;
     this.ImageLink   = imageLink;
     // use default value if no "price" provided
     if (price == null)
     {
         this.Price = 0D;
     }
     else
     {
         this.Price = price;
     }
     // use default value if no "salePrice" provided
     if (salePrice == null)
     {
         this.SalePrice = 0D;
     }
     else
     {
         this.SalePrice = salePrice;
     }
     this.Brand            = brand;
     this.Categories       = categories;
     this.RelatedProducts  = relatedProducts;
     this.CustomAttributes = customAttributes;
 }
 /// <summary>
 /// Initializes a new instance of the <see cref="ProductPatchRequest" /> class.
 /// </summary>
 /// <param name="name">Name of the product.</param>
 /// <param name="description">Description of the product.</param>
 /// <param name="sku">Stock Keeping Unit.</param>
 /// <param name="upc">Universal Product Code.</param>
 /// <param name="ean">European Article Numbering.</param>
 /// <param name="gtin">Global Trade Item Number.</param>
 /// <param name="mpn">Manufacturer Part Number.</param>
 /// <param name="link">Link for the product.</param>
 /// <param name="imageLink">Link for the product image.</param>
 /// <param name="price">Price of the product.</param>
 /// <param name="salePrice">Sale price of the product.</param>
 /// <param name="brand">Brand of the product.</param>
 /// <param name="categories">Array of product categories, using the character &#39;&gt;&#39; as delimiter for the breadcrumb                         syntax.</param>
 /// <param name="relatedProducts">relatedProducts.</param>
 public ProductPatchRequest(string name = default(string), string description = default(string), string sku = default(string), string upc = default(string), string ean = default(string), string gtin = default(string), string mpn = default(string), string link = default(string), string imageLink = default(string), double?price = default(double?), double?salePrice = default(double?), string brand = default(string), List <string> categories = default(List <string>), ProductPatchRequestRelatedProducts relatedProducts = default(ProductPatchRequestRelatedProducts))
 {
     this.Name            = name;
     this.Description     = description;
     this.Sku             = sku;
     this.Upc             = upc;
     this.Ean             = ean;
     this.Gtin            = gtin;
     this.Mpn             = mpn;
     this.Link            = link;
     this.ImageLink       = imageLink;
     this.Price           = price;
     this.SalePrice       = salePrice;
     this.Brand           = brand;
     this.Categories      = categories;
     this.RelatedProducts = relatedProducts;
 }