Package com.commercetools.api.models.me
Interface MyCartSetLineItemSupplyChannelAction
- All Superinterfaces:
MyCartUpdateAction,ResourceUpdateAction<MyCartUpdateAction>
Performing this action does not reserve stock. Stock is only reserved at Order creation if the InventoryMode of the Cart is TrackOnly or ReserveOnOrder.
This action is subject to InventoryEntry min/max restrictions when applicable. For more information, see Quantity limits.
Example to create an instance using the builder pattern
MyCartSetLineItemSupplyChannelAction myCartSetLineItemSupplyChannelAction = MyCartSetLineItemSupplyChannelAction.builder()
.build()
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Stringdiscriminator value for MyCartSetLineItemSupplyChannelAction -
Method Summary
Modifier and TypeMethodDescriptionbuilder()builder factory method for MyCartSetLineItemSupplyChannelActionbuilder(MyCartSetLineItemSupplyChannelAction template) create builder for MyCartSetLineItemSupplyChannelAction instancecopyDeep()deepCopy(MyCartSetLineItemSupplyChannelAction template) factory method to create a deep copy of MyCartSetLineItemSupplyChannelActionidof the LineItem to update.keyof the LineItem to update.@Valid ChannelResourceIdentifierof()factory methodof(MyCartSetLineItemSupplyChannelAction template) factory method to create a shallow copy MyCartSetLineItemSupplyChannelActionvoidsetLineItemId(String lineItemId) idof the LineItem to update.voidsetLineItemKey(String lineItemKey) keyof the LineItem to update.voidsetSupplyChannel(ChannelResourceIdentifier supplyChannel) static com.fasterxml.jackson.core.type.TypeReference<MyCartSetLineItemSupplyChannelAction>gives a TypeReference for usage with Jackson DataBinddefault <T> Taccessor map functionMethods inherited from interface com.commercetools.api.models.me.MyCartUpdateAction
getAction, withMyCartUpdateActionMethods inherited from interface com.commercetools.api.models.ResourceUpdateAction
get
-
Field Details
-
SET_LINE_ITEM_SUPPLY_CHANNEL
discriminator value for MyCartSetLineItemSupplyChannelAction- 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
-
getSupplyChannel
- If present, a Reference to the Channel is set for the LineItem specified by
lineItemId. - If not present, the current Reference to a supply channel will be removed from the LineItem specified by
lineItemId. The Channel must have theInventorySupplyChannelRoleEnum.
- Returns:
- supplyChannel
- If present, a Reference to the Channel is set for the LineItem specified by
-
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
-
setSupplyChannel
- If present, a Reference to the Channel is set for the LineItem specified by
lineItemId. - If not present, the current Reference to a supply channel will be removed from the LineItem specified by
lineItemId. The Channel must have theInventorySupplyChannelRoleEnum.
- Parameters:
supplyChannel- value to be set
- If present, a Reference to the Channel is set for the LineItem specified by
-
of
factory method- Returns:
- instance of MyCartSetLineItemSupplyChannelAction
-
of
factory method to create a shallow copy MyCartSetLineItemSupplyChannelAction- Parameters:
template- instance to be copied- Returns:
- copy instance
-
copyDeep
MyCartSetLineItemSupplyChannelAction copyDeep()- Specified by:
copyDeepin interfaceMyCartUpdateAction
-
deepCopy
@Nullable static MyCartSetLineItemSupplyChannelAction deepCopy(@Nullable MyCartSetLineItemSupplyChannelAction template) factory method to create a deep copy of MyCartSetLineItemSupplyChannelAction- Parameters:
template- instance to be copied- Returns:
- copy instance
-
builder
builder factory method for MyCartSetLineItemSupplyChannelAction- Returns:
- builder
-
builder
static MyCartSetLineItemSupplyChannelActionBuilder builder(MyCartSetLineItemSupplyChannelAction template) create builder for MyCartSetLineItemSupplyChannelAction instance- Parameters:
template- instance with prefilled values for the builder- Returns:
- builder
-
withMyCartSetLineItemSupplyChannelAction
default <T> T withMyCartSetLineItemSupplyChannelAction(Function<MyCartSetLineItemSupplyChannelAction, 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<MyCartSetLineItemSupplyChannelAction> typeReference()gives a TypeReference for usage with Jackson DataBind- Returns:
- TypeReference
-