Interface StagedOrderSetLineItemTaxAmountAction
- All Superinterfaces:
ResourceUpdateAction<StagedOrderUpdateAction>
,StagedOrderUpdateAction
Can be used if the Cart has the ExternalAmount
TaxMode. This update action sets the taxedPrice
and taxRate
on a Line Item and must be used after any price-affecting change occurs.
Example to create an instance using the builder pattern
StagedOrderSetLineItemTaxAmountAction stagedOrderSetLineItemTaxAmountAction = StagedOrderSetLineItemTaxAmountAction.builder()
.build()
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final String
discriminator value for StagedOrderSetLineItemTaxAmountAction -
Method Summary
Modifier and TypeMethodDescriptionbuilder()
builder factory method for StagedOrderSetLineItemTaxAmountActionbuilder
(StagedOrderSetLineItemTaxAmountAction template) create builder for StagedOrderSetLineItemTaxAmountAction instancefactory method to create a deep copy of StagedOrderSetLineItemTaxAmountAction@Valid ExternalTaxAmountDraft
Value to set.id
of the LineItem to update.key
of the LineItem to update.key
of the ShippingMethod used for this Line Item.of()
factory methodof
(StagedOrderSetLineItemTaxAmountAction template) factory method to create a shallow copy StagedOrderSetLineItemTaxAmountActionvoid
setExternalTaxAmount
(ExternalTaxAmountDraft externalTaxAmount) Value to set.void
setLineItemId
(String lineItemId) id
of the LineItem to update.void
setLineItemKey
(String lineItemKey) key
of the LineItem to update.void
setShippingKey
(String shippingKey) key
of the ShippingMethod used for this Line Item.static com.fasterxml.jackson.core.type.TypeReference<StagedOrderSetLineItemTaxAmountAction>
gives a TypeReference for usage with Jackson DataBinddefault <T> T
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_LINE_ITEM_TAX_AMOUNT
discriminator value for StagedOrderSetLineItemTaxAmountAction- See Also:
-
-
Method Details
-
getLineItemId
String getLineItemId()id
of the LineItem to update. EitherlineItemId
orlineItemKey
is required.- Returns:
- lineItemId
-
getLineItemKey
String getLineItemKey()key
of the LineItem to update. EitherlineItemId
orlineItemKey
is required.- Returns:
- lineItemKey
-
getExternalTaxAmount
Value to set. If empty, any existing value will be removed.
- Returns:
- externalTaxAmount
-
getShippingKey
String getShippingKey()key
of the ShippingMethod used for this Line Item. This is required for Carts withMultiple
ShippingMode.- Returns:
- shippingKey
-
setLineItemId
id
of the LineItem to update. EitherlineItemId
orlineItemKey
is required.- Parameters:
lineItemId
- value to be set
-
setLineItemKey
key
of the LineItem to update. EitherlineItemId
orlineItemKey
is required.- Parameters:
lineItemKey
- value to be set
-
setExternalTaxAmount
Value to set. If empty, any existing value will be removed.
- Parameters:
externalTaxAmount
- value to be set
-
setShippingKey
key
of the ShippingMethod used for this Line Item. This is required for Carts withMultiple
ShippingMode.- Parameters:
shippingKey
- value to be set
-
of
factory method- Returns:
- instance of StagedOrderSetLineItemTaxAmountAction
-
of
factory method to create a shallow copy StagedOrderSetLineItemTaxAmountAction- Parameters:
template
- instance to be copied- Returns:
- copy instance
-
deepCopy
@Nullable static StagedOrderSetLineItemTaxAmountAction deepCopy(@Nullable StagedOrderSetLineItemTaxAmountAction template) factory method to create a deep copy of StagedOrderSetLineItemTaxAmountAction- Parameters:
template
- instance to be copied- Returns:
- copy instance
-
builder
builder factory method for StagedOrderSetLineItemTaxAmountAction- Returns:
- builder
-
builder
static StagedOrderSetLineItemTaxAmountActionBuilder builder(StagedOrderSetLineItemTaxAmountAction template) create builder for StagedOrderSetLineItemTaxAmountAction instance- Parameters:
template
- instance with prefilled values for the builder- Returns:
- builder
-
withStagedOrderSetLineItemTaxAmountAction
default <T> T withStagedOrderSetLineItemTaxAmountAction(Function<StagedOrderSetLineItemTaxAmountAction, 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<StagedOrderSetLineItemTaxAmountAction> typeReference()gives a TypeReference for usage with Jackson DataBind- Returns:
- TypeReference
-