Total tax applicable for the Cart or Order.
+ * @return totalTax + */ + @Valid + @JsonProperty("totalTax") + public TypedMoneyDraft getTotalTax(); + /** *Total net price of the Cart or Order.
* @param totalNet value to be set @@ -94,6 +103,13 @@ public interface TaxedPriceDraft extends io.vrap.rmf.base.client.DraftTotal tax applicable for the Cart or Order.
+ * @param totalTax value to be set + */ + + public void setTotalTax(final TypedMoneyDraft totalTax); + /** * factory method * @return instance of TaxedPriceDraft @@ -112,6 +128,7 @@ public static TaxedPriceDraft of(final TaxedPriceDraft template) { instance.setTotalNet(template.getTotalNet()); instance.setTotalGross(template.getTotalGross()); instance.setTaxPortions(template.getTaxPortions()); + instance.setTotalTax(template.getTotalTax()); return instance; } @@ -133,6 +150,7 @@ public static TaxedPriceDraft deepCopy(@Nullable final TaxedPriceDraft template) .map(com.commercetools.api.models.cart.TaxPortionDraft::deepCopy) .collect(Collectors.toList())) .orElse(null)); + instance.setTotalTax(com.commercetools.api.models.common.TypedMoneyDraft.deepCopy(template.getTotalTax())); return instance; } diff --git a/commercetools/commercetools-sdk-java-api/src/main/java-generated/com/commercetools/api/models/cart/TaxedPriceDraftBuilder.java b/commercetools/commercetools-sdk-java-api/src/main/java-generated/com/commercetools/api/models/cart/TaxedPriceDraftBuilder.java index 9328edae371..4cd00aa2551 100644 --- a/commercetools/commercetools-sdk-java-api/src/main/java-generated/com/commercetools/api/models/cart/TaxedPriceDraftBuilder.java +++ b/commercetools/commercetools-sdk-java-api/src/main/java-generated/com/commercetools/api/models/cart/TaxedPriceDraftBuilder.java @@ -4,6 +4,8 @@ import java.util.*; import java.util.function.Function; +import javax.annotation.Nullable; + import io.vrap.rmf.base.client.Builder; import io.vrap.rmf.base.client.utils.Generated; @@ -30,6 +32,9 @@ public class TaxedPriceDraftBuilder implements BuilderTotal net price of the Cart or Order.
* @param builder function to build the totalNet value @@ -195,6 +200,30 @@ public TaxedPriceDraftBuilder setTaxPortions( return taxPortions(builder.apply(com.commercetools.api.models.cart.TaxPortionDraftBuilder.of())); } + /** + *Total tax applicable for the Cart or Order.
+ * @param totalTax value to be set + * @return Builder + */ + + public TaxedPriceDraftBuilder totalTax( + @Nullable final com.commercetools.api.models.common.TypedMoneyDraft totalTax) { + this.totalTax = totalTax; + return this; + } + + /** + *Total tax applicable for the Cart or Order.
+ * @param builder function to build the totalTax value + * @return Builder + */ + + public TaxedPriceDraftBuilder totalTax( + FunctionTotal net price of the Cart or Order.
* @return totalNet @@ -223,6 +252,16 @@ public java.util.ListTotal tax applicable for the Cart or Order.
+ * @return totalTax + */ + + @Nullable + public com.commercetools.api.models.common.TypedMoneyDraft getTotalTax() { + return this.totalTax; + } + /** * builds TaxedPriceDraft with checking for non-null required values * @return TaxedPriceDraft @@ -231,7 +270,7 @@ public TaxedPriceDraft build() { Objects.requireNonNull(totalNet, TaxedPriceDraft.class + ": totalNet is missing"); Objects.requireNonNull(totalGross, TaxedPriceDraft.class + ": totalGross is missing"); Objects.requireNonNull(taxPortions, TaxedPriceDraft.class + ": taxPortions is missing"); - return new TaxedPriceDraftImpl(totalNet, totalGross, taxPortions); + return new TaxedPriceDraftImpl(totalNet, totalGross, taxPortions, totalTax); } /** @@ -239,7 +278,7 @@ public TaxedPriceDraft build() { * @return TaxedPriceDraft */ public TaxedPriceDraft buildUnchecked() { - return new TaxedPriceDraftImpl(totalNet, totalGross, taxPortions); + return new TaxedPriceDraftImpl(totalNet, totalGross, taxPortions, totalTax); } /** @@ -260,6 +299,7 @@ public static TaxedPriceDraftBuilder of(final TaxedPriceDraft template) { builder.totalNet = template.getTotalNet(); builder.totalGross = template.getTotalGross(); builder.taxPortions = template.getTaxPortions(); + builder.totalTax = template.getTotalTax(); return builder; } diff --git a/commercetools/commercetools-sdk-java-api/src/main/java-generated/com/commercetools/api/models/cart/TaxedPriceDraftImpl.java b/commercetools/commercetools-sdk-java-api/src/main/java-generated/com/commercetools/api/models/cart/TaxedPriceDraftImpl.java index dbf4ee43f23..b3bb5a4b930 100644 --- a/commercetools/commercetools-sdk-java-api/src/main/java-generated/com/commercetools/api/models/cart/TaxedPriceDraftImpl.java +++ b/commercetools/commercetools-sdk-java-api/src/main/java-generated/com/commercetools/api/models/cart/TaxedPriceDraftImpl.java @@ -28,16 +28,20 @@ public class TaxedPriceDraftImpl implements TaxedPriceDraft, ModelBase { private java.util.ListTotal tax applicable for the Cart or Order.
+ */ + + public com.commercetools.api.models.common.TypedMoneyDraft getTotalTax() { + return this.totalTax; + } + public void setTotalNet(final com.commercetools.api.models.common.Money totalNet) { this.totalNet = totalNet; } @@ -87,6 +99,10 @@ public void setTaxPortions(final java.util.List