Package com.commercetools.api.models.me
Interface MyShoppingListChangeLineItemQuantityAction
- All Superinterfaces:
MyShoppingListUpdateAction
,ResourceUpdateAction<MyShoppingListUpdateAction>
MyShoppingListChangeLineItemQuantityAction
Example to create an instance using the builder pattern
Example to create an instance using the builder pattern
MyShoppingListChangeLineItemQuantityAction myShoppingListChangeLineItemQuantityAction = MyShoppingListChangeLineItemQuantityAction.builder()
.quantity(0.3)
.build()
-
Field Summary
Modifier and TypeFieldDescriptionstatic final String
discriminator value for MyShoppingListChangeLineItemQuantityAction -
Method Summary
Modifier and TypeMethodDescriptionbuilder()
builder factory method for MyShoppingListChangeLineItemQuantityActioncreate builder for MyShoppingListChangeLineItemQuantityAction instancefactory method to create a deep copy of MyShoppingListChangeLineItemQuantityActionid
of the ShoppingListLineItem to update.key
of the ShoppingListLineItem to update.@NotNull Long
New value to set.of()
factory methodof
(MyShoppingListChangeLineItemQuantityAction template) factory method to create a shallow copy MyShoppingListChangeLineItemQuantityActionvoid
setLineItemId
(String lineItemId) id
of the ShoppingListLineItem to update.void
setLineItemKey
(String lineItemKey) key
of the ShoppingListLineItem to update.void
setQuantity
(Long quantity) New value to set.static com.fasterxml.jackson.core.type.TypeReference<MyShoppingListChangeLineItemQuantityAction>
gives a TypeReference for usage with Jackson DataBinddefault <T> T
withMyShoppingListChangeLineItemQuantityAction
(Function<MyShoppingListChangeLineItemQuantityAction, T> helper) accessor map functionMethods inherited from interface com.commercetools.api.models.me.MyShoppingListUpdateAction
getAction, withMyShoppingListUpdateAction
Methods inherited from interface com.commercetools.api.models.ResourceUpdateAction
get
-
Field Details
-
CHANGE_LINE_ITEM_QUANTITY
discriminator value for MyShoppingListChangeLineItemQuantityAction- See Also:
-
-
Method Details
-
getLineItemId
String getLineItemId()id
of the ShoppingListLineItem to update. EitherlineItemId
orlineItemKey
is required.- Returns:
- lineItemId
-
getLineItemKey
String getLineItemKey()key
of the ShoppingListLineItem to update. EitherlineItemId
orlineItemKey
is required.- Returns:
- lineItemKey
-
getQuantity
New value to set. If
0
, the ShoppingListLineItem is removed from the ShoppingList.- Returns:
- quantity
-
setLineItemId
id
of the ShoppingListLineItem to update. EitherlineItemId
orlineItemKey
is required.- Parameters:
lineItemId
- value to be set
-
setLineItemKey
key
of the ShoppingListLineItem to update. EitherlineItemId
orlineItemKey
is required.- Parameters:
lineItemKey
- value to be set
-
setQuantity
New value to set. If
0
, the ShoppingListLineItem is removed from the ShoppingList.- Parameters:
quantity
- value to be set
-
of
factory method- Returns:
- instance of MyShoppingListChangeLineItemQuantityAction
-
of
static MyShoppingListChangeLineItemQuantityAction of(MyShoppingListChangeLineItemQuantityAction template) factory method to create a shallow copy MyShoppingListChangeLineItemQuantityAction- Parameters:
template
- instance to be copied- Returns:
- copy instance
-
deepCopy
@Nullable static MyShoppingListChangeLineItemQuantityAction deepCopy(@Nullable MyShoppingListChangeLineItemQuantityAction template) factory method to create a deep copy of MyShoppingListChangeLineItemQuantityAction- Parameters:
template
- instance to be copied- Returns:
- copy instance
-
builder
builder factory method for MyShoppingListChangeLineItemQuantityAction- Returns:
- builder
-
builder
static MyShoppingListChangeLineItemQuantityActionBuilder builder(MyShoppingListChangeLineItemQuantityAction template) create builder for MyShoppingListChangeLineItemQuantityAction instance- Parameters:
template
- instance with prefilled values for the builder- Returns:
- builder
-
withMyShoppingListChangeLineItemQuantityAction
default <T> T withMyShoppingListChangeLineItemQuantityAction(Function<MyShoppingListChangeLineItemQuantityAction, 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<MyShoppingListChangeLineItemQuantityAction> typeReference()gives a TypeReference for usage with Jackson DataBind- Returns:
- TypeReference
-