Class MethodExternalTaxRateDraftBuilder
java.lang.Object
com.commercetools.api.models.cart.MethodExternalTaxRateDraftBuilder
- All Implemented Interfaces:
Builder<MethodExternalTaxRateDraft>
public class MethodExternalTaxRateDraftBuilder
extends Object
implements Builder<MethodExternalTaxRateDraft>
MethodExternalTaxRateDraftBuilder
Example to create an instance using the builder pattern
Example to create an instance using the builder pattern
MethodExternalTaxRateDraft methodExternalTaxRateDraft = MethodExternalTaxRateDraft.builder()
.shippingMethodKey("{shippingMethodKey}")
.build()
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionbuild()
builds MethodExternalTaxRateDraft with checking for non-null required valuesbuilds MethodExternalTaxRateDraft without checking for non-null required valuesUser-defined unique identifier of the Shipping Method in a Cart withMultiple
ShippingMode.External Tax Rate for the Shipping Method, if the Cart hasExternal
TaxMode.of()
factory method for an instance of MethodExternalTaxRateDraftBuilderof
(MethodExternalTaxRateDraft template) create builder for MethodExternalTaxRateDraft instanceshippingMethodKey
(String shippingMethodKey) User-defined unique identifier of the Shipping Method in a Cart withMultiple
ShippingMode.taxRate
(ExternalTaxRateDraft taxRate) External Tax Rate for the Shipping Method, if the Cart hasExternal
TaxMode.External Tax Rate for the Shipping Method, if the Cart hasExternal
TaxMode.External Tax Rate for the Shipping Method, if the Cart hasExternal
TaxMode.
-
Constructor Details
-
MethodExternalTaxRateDraftBuilder
public MethodExternalTaxRateDraftBuilder()
-
-
Method Details
-
shippingMethodKey
User-defined unique identifier of the Shipping Method in a Cart with
Multiple
ShippingMode.- Parameters:
shippingMethodKey
- value to be set- Returns:
- Builder
-
taxRate
public MethodExternalTaxRateDraftBuilder taxRate(Function<ExternalTaxRateDraftBuilder, ExternalTaxRateDraftBuilder> builder) External Tax Rate for the Shipping Method, if the Cart has
External
TaxMode.- Parameters:
builder
- function to build the taxRate value- Returns:
- Builder
-
withTaxRate
public MethodExternalTaxRateDraftBuilder withTaxRate(Function<ExternalTaxRateDraftBuilder, ExternalTaxRateDraft> builder) External Tax Rate for the Shipping Method, if the Cart has
External
TaxMode.- Parameters:
builder
- function to build the taxRate value- Returns:
- Builder
-
taxRate
External Tax Rate for the Shipping Method, if the Cart has
External
TaxMode.- Parameters:
taxRate
- value to be set- Returns:
- Builder
-
getShippingMethodKey
User-defined unique identifier of the Shipping Method in a Cart with
Multiple
ShippingMode.- Returns:
- shippingMethodKey
-
getTaxRate
External Tax Rate for the Shipping Method, if the Cart has
External
TaxMode.- Returns:
- taxRate
-
build
builds MethodExternalTaxRateDraft with checking for non-null required values- Specified by:
build
in interfaceBuilder<MethodExternalTaxRateDraft>
- Returns:
- MethodExternalTaxRateDraft
-
buildUnchecked
builds MethodExternalTaxRateDraft without checking for non-null required values- Returns:
- MethodExternalTaxRateDraft
-
of
factory method for an instance of MethodExternalTaxRateDraftBuilder- Returns:
- builder
-
of
create builder for MethodExternalTaxRateDraft instance- Parameters:
template
- instance with prefilled values for the builder- Returns:
- builder
-