Class CartSetShippingMethodTaxRateActionBuilder
java.lang.Object
com.commercetools.api.models.cart.CartSetShippingMethodTaxRateActionBuilder
- All Implemented Interfaces:
Builder<CartSetShippingMethodTaxRateAction>
public class CartSetShippingMethodTaxRateActionBuilder
extends Object
implements Builder<CartSetShippingMethodTaxRateAction>
CartSetShippingMethodTaxRateActionBuilder
Example to create an instance using the builder pattern
Example to create an instance using the builder pattern
CartSetShippingMethodTaxRateAction cartSetShippingMethodTaxRateAction = CartSetShippingMethodTaxRateAction.builder()
.build()
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()builds CartSetShippingMethodTaxRateAction with checking for non-null required valuesbuilds CartSetShippingMethodTaxRateAction without checking for non-null required valuesexternalTaxRate(ExternalTaxRateDraft externalTaxRate) Value to set.Value to set.Value to set.keyof the ShippingMethod to update.of()factory method for an instance of CartSetShippingMethodTaxRateActionBuilderof(CartSetShippingMethodTaxRateAction template) create builder for CartSetShippingMethodTaxRateAction instanceshippingKey(String shippingKey) keyof the ShippingMethod to update.Value to set.
-
Constructor Details
-
CartSetShippingMethodTaxRateActionBuilder
public CartSetShippingMethodTaxRateActionBuilder()
-
-
Method Details
-
shippingKey
keyof the ShippingMethod to update. This is required for Carts withMultipleShippingMode.- Parameters:
shippingKey- value to be set- Returns:
- Builder
-
externalTaxRate
public CartSetShippingMethodTaxRateActionBuilder externalTaxRate(Function<ExternalTaxRateDraftBuilder, ExternalTaxRateDraftBuilder> builder) Value to set. If empty, any existing value is removed.
- Parameters:
builder- function to build the externalTaxRate value- Returns:
- Builder
-
withExternalTaxRate
public CartSetShippingMethodTaxRateActionBuilder withExternalTaxRate(Function<ExternalTaxRateDraftBuilder, ExternalTaxRateDraft> builder) Value to set. If empty, any existing value is removed.
- Parameters:
builder- function to build the externalTaxRate value- Returns:
- Builder
-
externalTaxRate
public CartSetShippingMethodTaxRateActionBuilder externalTaxRate(@Nullable ExternalTaxRateDraft externalTaxRate) Value to set. If empty, any existing value is removed.
- Parameters:
externalTaxRate- value to be set- Returns:
- Builder
-
getShippingKey
keyof the ShippingMethod to update. This is required for Carts withMultipleShippingMode.- Returns:
- shippingKey
-
getExternalTaxRate
Value to set. If empty, any existing value is removed.
- Returns:
- externalTaxRate
-
build
builds CartSetShippingMethodTaxRateAction with checking for non-null required values- Specified by:
buildin interfaceBuilder<CartSetShippingMethodTaxRateAction>- Returns:
- CartSetShippingMethodTaxRateAction
-
buildUnchecked
builds CartSetShippingMethodTaxRateAction without checking for non-null required values- Returns:
- CartSetShippingMethodTaxRateAction
-
of
factory method for an instance of CartSetShippingMethodTaxRateActionBuilder- Returns:
- builder
-
of
public static CartSetShippingMethodTaxRateActionBuilder of(CartSetShippingMethodTaxRateAction template) create builder for CartSetShippingMethodTaxRateAction instance- Parameters:
template- instance with prefilled values for the builder- Returns:
- builder
-