Interface InventoryEntryRemoveQuantityAction
- All Superinterfaces:
InventoryEntryUpdateAction
,ResourceUpdateAction<InventoryEntryUpdateAction>
Updates availableQuantity
based on the new quantityOnStock
and amount of active reservations.
Example to create an instance using the builder pattern
InventoryEntryRemoveQuantityAction inventoryEntryRemoveQuantityAction = InventoryEntryRemoveQuantityAction.builder()
.quantity(0.3)
.build()
-
Field Summary
Modifier and TypeFieldDescriptionstatic final String
discriminator value for InventoryEntryRemoveQuantityAction -
Method Summary
Modifier and TypeMethodDescriptionbuilder()
builder factory method for InventoryEntryRemoveQuantityActionbuilder
(InventoryEntryRemoveQuantityAction template) create builder for InventoryEntryRemoveQuantityAction instancedeepCopy
(InventoryEntryRemoveQuantityAction template) factory method to create a deep copy of InventoryEntryRemoveQuantityAction@NotNull Long
Value to remove fromquantityOnStock
.of()
factory methodof
(InventoryEntryRemoveQuantityAction template) factory method to create a shallow copy InventoryEntryRemoveQuantityActionvoid
setQuantity
(Long quantity) Value to remove fromquantityOnStock
.static com.fasterxml.jackson.core.type.TypeReference<InventoryEntryRemoveQuantityAction>
gives a TypeReference for usage with Jackson DataBinddefault <T> T
accessor map functionMethods inherited from interface com.commercetools.api.models.inventory.InventoryEntryUpdateAction
getAction, withInventoryEntryUpdateAction
Methods inherited from interface com.commercetools.api.models.ResourceUpdateAction
get
-
Field Details
-
REMOVE_QUANTITY
discriminator value for InventoryEntryRemoveQuantityAction- See Also:
-
-
Method Details
-
getQuantity
Value to remove from
quantityOnStock
.- Returns:
- quantity
-
setQuantity
Value to remove from
quantityOnStock
.- Parameters:
quantity
- value to be set
-
of
factory method- Returns:
- instance of InventoryEntryRemoveQuantityAction
-
of
factory method to create a shallow copy InventoryEntryRemoveQuantityAction- Parameters:
template
- instance to be copied- Returns:
- copy instance
-
deepCopy
@Nullable static InventoryEntryRemoveQuantityAction deepCopy(@Nullable InventoryEntryRemoveQuantityAction template) factory method to create a deep copy of InventoryEntryRemoveQuantityAction- Parameters:
template
- instance to be copied- Returns:
- copy instance
-
builder
builder factory method for InventoryEntryRemoveQuantityAction- Returns:
- builder
-
builder
static InventoryEntryRemoveQuantityActionBuilder builder(InventoryEntryRemoveQuantityAction template) create builder for InventoryEntryRemoveQuantityAction instance- Parameters:
template
- instance with prefilled values for the builder- Returns:
- builder
-
withInventoryEntryRemoveQuantityAction
default <T> T withInventoryEntryRemoveQuantityAction(Function<InventoryEntryRemoveQuantityAction, 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<InventoryEntryRemoveQuantityAction> typeReference()gives a TypeReference for usage with Jackson DataBind- Returns:
- TypeReference
-