Interface StagedOrderSetShippingAddressAndCustomShippingMethodAction
- All Superinterfaces:
ResourceUpdateAction<StagedOrderUpdateAction>
,StagedOrderUpdateAction
public interface StagedOrderSetShippingAddressAndCustomShippingMethodAction
extends StagedOrderUpdateAction
Sets the shipping address and a custom Shipping Method together to prevent an inconsistent state.
Example to create an instance using the builder pattern
StagedOrderSetShippingAddressAndCustomShippingMethodAction stagedOrderSetShippingAddressAndCustomShippingMethodAction = StagedOrderSetShippingAddressAndCustomShippingMethodAction.builder()
.address(addressBuilder -> addressBuilder)
.shippingMethodName("{shippingMethodName}")
.shippingRate(shippingRateBuilder -> shippingRateBuilder)
.build()
-
Field Summary
Modifier and TypeFieldDescriptionstatic final String
discriminator value for StagedOrderSetShippingAddressAndCustomShippingMethodAction -
Method Summary
Modifier and TypeMethodDescriptionbuilder()
builder factory method for StagedOrderSetShippingAddressAndCustomShippingMethodActioncreate builder for StagedOrderSetShippingAddressAndCustomShippingMethodAction instancefactory method to create a deep copy of StagedOrderSetShippingAddressAndCustomShippingMethodAction@NotNull @Valid BaseAddress
Value to set forshippingAddress
.@Valid ExternalTaxRateDraft
An external Tax Rate can be set if the Cart has theExternal
TaxMode.@NotNull String
Value to set.@NotNull @Valid ShippingRateDraft
Value to set.Used to select a Tax Rate when the Order has thePlatform
TaxMode.of()
factory methodfactory method to create a shallow copy StagedOrderSetShippingAddressAndCustomShippingMethodActionvoid
setAddress
(BaseAddress address) Value to set forshippingAddress
.void
setExternalTaxRate
(ExternalTaxRateDraft externalTaxRate) An external Tax Rate can be set if the Cart has theExternal
TaxMode.void
setShippingMethodName
(String shippingMethodName) Value to set.void
setShippingRate
(ShippingRateDraft shippingRate) Value to set.void
setTaxCategory
(TaxCategoryResourceIdentifier taxCategory) Used to select a Tax Rate when the Order has thePlatform
TaxMode.static com.fasterxml.jackson.core.type.TypeReference<StagedOrderSetShippingAddressAndCustomShippingMethodAction>
gives a TypeReference for usage with Jackson DataBinddefault <T> T
withStagedOrderSetShippingAddressAndCustomShippingMethodAction
(Function<StagedOrderSetShippingAddressAndCustomShippingMethodAction, T> helper) accessor map functionMethods inherited from interface com.commercetools.api.models.ResourceUpdateAction
get
Methods inherited from interface com.commercetools.api.models.order.StagedOrderUpdateAction
getAction, withStagedOrderUpdateAction
-
Field Details
-
SET_SHIPPING_ADDRESS_AND_CUSTOM_SHIPPING_METHOD
discriminator value for StagedOrderSetShippingAddressAndCustomShippingMethodAction- See Also:
-
-
Method Details
-
getAddress
Value to set for
shippingAddress
.- Returns:
- address
-
getShippingMethodName
Value to set.
- Returns:
- shippingMethodName
-
getShippingRate
Value to set.
- Returns:
- shippingRate
-
getTaxCategory
Used to select a Tax Rate when the Order has the
Platform
TaxMode.- Returns:
- taxCategory
-
getExternalTaxRate
An external Tax Rate can be set if the Cart has the
External
TaxMode.- Returns:
- externalTaxRate
-
setAddress
Value to set for
shippingAddress
.- Parameters:
address
- value to be set
-
setShippingMethodName
Value to set.
- Parameters:
shippingMethodName
- value to be set
-
setShippingRate
Value to set.
- Parameters:
shippingRate
- value to be set
-
setTaxCategory
Used to select a Tax Rate when the Order has the
Platform
TaxMode.- Parameters:
taxCategory
- value to be set
-
setExternalTaxRate
An external Tax Rate can be set if the Cart has the
External
TaxMode.- Parameters:
externalTaxRate
- value to be set
-
of
factory method- Returns:
- instance of StagedOrderSetShippingAddressAndCustomShippingMethodAction
-
of
static StagedOrderSetShippingAddressAndCustomShippingMethodAction of(StagedOrderSetShippingAddressAndCustomShippingMethodAction template) factory method to create a shallow copy StagedOrderSetShippingAddressAndCustomShippingMethodAction- Parameters:
template
- instance to be copied- Returns:
- copy instance
-
deepCopy
@Nullable static StagedOrderSetShippingAddressAndCustomShippingMethodAction deepCopy(@Nullable StagedOrderSetShippingAddressAndCustomShippingMethodAction template) factory method to create a deep copy of StagedOrderSetShippingAddressAndCustomShippingMethodAction- Parameters:
template
- instance to be copied- Returns:
- copy instance
-
builder
builder factory method for StagedOrderSetShippingAddressAndCustomShippingMethodAction- Returns:
- builder
-
builder
static StagedOrderSetShippingAddressAndCustomShippingMethodActionBuilder builder(StagedOrderSetShippingAddressAndCustomShippingMethodAction template) create builder for StagedOrderSetShippingAddressAndCustomShippingMethodAction instance- Parameters:
template
- instance with prefilled values for the builder- Returns:
- builder
-
withStagedOrderSetShippingAddressAndCustomShippingMethodAction
default <T> T withStagedOrderSetShippingAddressAndCustomShippingMethodAction(Function<StagedOrderSetShippingAddressAndCustomShippingMethodAction, T> helper) accessor map function- Type Parameters:
T
- mapped type- Parameters:
helper
- function to map the object- Returns:
- mapped value
-
typeReference
static com.fasterxml.jackson.core.type.TypeReference<StagedOrderSetShippingAddressAndCustomShippingMethodAction> typeReference()gives a TypeReference for usage with Jackson DataBind- Returns:
- TypeReference
-