Interface CartSetLineItemTaxAmountAction
- All Superinterfaces:
CartUpdateAction,ResourceUpdateAction<CartUpdateAction>
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
CartSetLineItemTaxAmountAction cartSetLineItemTaxAmountAction = CartSetLineItemTaxAmountAction.builder()
.build()
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Stringdiscriminator value for CartSetLineItemTaxAmountAction -
Method Summary
Modifier and TypeMethodDescriptionbuilder()builder factory method for CartSetLineItemTaxAmountActionbuilder(CartSetLineItemTaxAmountAction template) create builder for CartSetLineItemTaxAmountAction instancecopyDeep()deepCopy(CartSetLineItemTaxAmountAction template) factory method to create a deep copy of CartSetLineItemTaxAmountAction@Valid ExternalTaxAmountDraftValue to set.idof the LineItem to update.keyof the LineItem to update.keyof the ShippingMethod used for this Line Item.of()factory methodof(CartSetLineItemTaxAmountAction template) factory method to create a shallow copy CartSetLineItemTaxAmountActionvoidsetExternalTaxAmount(ExternalTaxAmountDraft externalTaxAmount) Value to set.voidsetLineItemId(String lineItemId) idof the LineItem to update.voidsetLineItemKey(String lineItemKey) keyof the LineItem to update.voidsetShippingKey(String shippingKey) keyof the ShippingMethod used for this Line Item.static com.fasterxml.jackson.core.type.TypeReference<CartSetLineItemTaxAmountAction>gives a TypeReference for usage with Jackson DataBinddefault <T> Taccessor map functionMethods inherited from interface com.commercetools.api.models.cart.CartUpdateAction
getAction, withCartUpdateActionMethods inherited from interface com.commercetools.api.models.ResourceUpdateAction
get
-
Field Details
-
SET_LINE_ITEM_TAX_AMOUNT
discriminator value for CartSetLineItemTaxAmountAction- See Also:
-
-
Method Details
-
getLineItemId
String getLineItemId()idof the LineItem to update. EitherlineItemIdorlineItemKeyis required.- Returns:
- lineItemId
-
getLineItemKey
String getLineItemKey()keyof the LineItem to update. EitherlineItemIdorlineItemKeyis required.- Returns:
- lineItemKey
-
getExternalTaxAmount
Value to set. If empty, any existing value is removed.
- Returns:
- externalTaxAmount
-
getShippingKey
String getShippingKey()keyof the ShippingMethod used for this Line Item. This is required for Carts withMultipleShippingMode.- Returns:
- shippingKey
-
setLineItemId
idof the LineItem to update. EitherlineItemIdorlineItemKeyis required.- Parameters:
lineItemId- value to be set
-
setLineItemKey
keyof the LineItem to update. EitherlineItemIdorlineItemKeyis required.- Parameters:
lineItemKey- value to be set
-
setExternalTaxAmount
Value to set. If empty, any existing value is removed.
- Parameters:
externalTaxAmount- value to be set
-
setShippingKey
keyof the ShippingMethod used for this Line Item. This is required for Carts withMultipleShippingMode.- Parameters:
shippingKey- value to be set
-
of
factory method- Returns:
- instance of CartSetLineItemTaxAmountAction
-
of
factory method to create a shallow copy CartSetLineItemTaxAmountAction- Parameters:
template- instance to be copied- Returns:
- copy instance
-
copyDeep
CartSetLineItemTaxAmountAction copyDeep()- Specified by:
copyDeepin interfaceCartUpdateAction
-
deepCopy
@Nullable static CartSetLineItemTaxAmountAction deepCopy(@Nullable CartSetLineItemTaxAmountAction template) factory method to create a deep copy of CartSetLineItemTaxAmountAction- Parameters:
template- instance to be copied- Returns:
- copy instance
-
builder
builder factory method for CartSetLineItemTaxAmountAction- Returns:
- builder
-
builder
create builder for CartSetLineItemTaxAmountAction instance- Parameters:
template- instance with prefilled values for the builder- Returns:
- builder
-
withCartSetLineItemTaxAmountAction
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<CartSetLineItemTaxAmountAction> typeReference()gives a TypeReference for usage with Jackson DataBind- Returns:
- TypeReference
-