Interface StagedOrderSetShippingMethodAction
- All Superinterfaces:
ResourceUpdateAction<StagedOrderUpdateAction>,StagedOrderUpdateAction
To set the Cart's Shipping Method, the Cart must have the Single ShippingMode and a shippingAddress.
Example to create an instance using the builder pattern
StagedOrderSetShippingMethodAction stagedOrderSetShippingMethodAction = StagedOrderSetShippingMethodAction.builder()
.build()
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Stringdiscriminator value for StagedOrderSetShippingMethodAction -
Method Summary
Modifier and TypeMethodDescriptionbuilder()builder factory method for StagedOrderSetShippingMethodActionbuilder(StagedOrderSetShippingMethodAction template) create builder for StagedOrderSetShippingMethodAction instancecopyDeep()deepCopy(StagedOrderSetShippingMethodAction template) factory method to create a deep copy of StagedOrderSetShippingMethodAction@Valid ExternalTaxRateDraftAn external Tax Rate can be set if the Cart has theExternalTaxMode.Value to set.of()factory methodof(StagedOrderSetShippingMethodAction template) factory method to create a shallow copy StagedOrderSetShippingMethodActionvoidsetExternalTaxRate(ExternalTaxRateDraft externalTaxRate) An external Tax Rate can be set if the Cart has theExternalTaxMode.voidsetShippingMethod(ShippingMethodResourceIdentifier shippingMethod) Value to set.static com.fasterxml.jackson.core.type.TypeReference<StagedOrderSetShippingMethodAction>gives a TypeReference for usage with Jackson DataBinddefault <T> Taccessor map functionMethods inherited from interface com.commercetools.api.models.ResourceUpdateAction
getMethods inherited from interface com.commercetools.api.models.order.StagedOrderUpdateAction
getAction, withStagedOrderUpdateAction
-
Field Details
-
SET_SHIPPING_METHOD
discriminator value for StagedOrderSetShippingMethodAction- See Also:
-
-
Method Details
-
getShippingMethod
Value to set. If empty, any existing value will be removed. If the referenced Shipping Method has a predicate that does not match the Cart, an InvalidOperation error is returned.
- Returns:
- shippingMethod
-
getExternalTaxRate
An external Tax Rate can be set if the Cart has the
ExternalTaxMode.- Returns:
- externalTaxRate
-
setShippingMethod
Value to set. If empty, any existing value will be removed. If the referenced Shipping Method has a predicate that does not match the Cart, an InvalidOperation error is returned.
- Parameters:
shippingMethod- value to be set
-
setExternalTaxRate
An external Tax Rate can be set if the Cart has the
ExternalTaxMode.- Parameters:
externalTaxRate- value to be set
-
of
factory method- Returns:
- instance of StagedOrderSetShippingMethodAction
-
of
factory method to create a shallow copy StagedOrderSetShippingMethodAction- Parameters:
template- instance to be copied- Returns:
- copy instance
-
copyDeep
StagedOrderSetShippingMethodAction copyDeep()- Specified by:
copyDeepin interfaceStagedOrderUpdateAction
-
deepCopy
@Nullable static StagedOrderSetShippingMethodAction deepCopy(@Nullable StagedOrderSetShippingMethodAction template) factory method to create a deep copy of StagedOrderSetShippingMethodAction- Parameters:
template- instance to be copied- Returns:
- copy instance
-
builder
builder factory method for StagedOrderSetShippingMethodAction- Returns:
- builder
-
builder
static StagedOrderSetShippingMethodActionBuilder builder(StagedOrderSetShippingMethodAction template) create builder for StagedOrderSetShippingMethodAction instance- Parameters:
template- instance with prefilled values for the builder- Returns:
- builder
-
withStagedOrderSetShippingMethodAction
default <T> T withStagedOrderSetShippingMethodAction(Function<StagedOrderSetShippingMethodAction, 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<StagedOrderSetShippingMethodAction> typeReference()gives a TypeReference for usage with Jackson DataBind- Returns:
- TypeReference
-