Interface InventoryEntryQuantitySetMessage
- All Superinterfaces:
BaseResource
,DomainResource<Message>
,Identifiable<Message>
,Message
,Versioned<Message>
Generated after a successful Add Quantity, Remove Quantity or Change Quantity update action. Inventory changes as a result of Order creation do not trigger this message.
Example to create an instance using the builder pattern
InventoryEntryQuantitySetMessage inventoryEntryQuantitySetMessage = InventoryEntryQuantitySetMessage.builder()
.id("{id}")
.version(0.3)
.createdAt(ZonedDateTime.parse("2022-01-01T12:00:00.301Z"))
.lastModifiedAt(ZonedDateTime.parse("2022-01-01T12:00:00.301Z"))
.sequenceNumber(0.3)
.resource(resourceBuilder -> resourceBuilder)
.resourceVersion(0.3)
.oldQuantityOnStock(0.3)
.newQuantityOnStock(0.3)
.oldAvailableQuantity(0.3)
.newAvailableQuantity(0.3)
.build()
-
Field Summary
Modifier and TypeFieldDescriptionstatic final String
discriminator value for InventoryEntryQuantitySetMessage -
Method Summary
Modifier and TypeMethodDescriptionbuilder()
builder factory method for InventoryEntryQuantitySetMessagebuilder
(InventoryEntryQuantitySetMessage template) create builder for InventoryEntryQuantitySetMessage instancedeepCopy
(InventoryEntryQuantitySetMessage template) factory method to create a deep copy of InventoryEntryQuantitySetMessage@NotNull Long
Available quantity for the InventoryEntry after the quantity was updated.@NotNull Long
Quantity on stock for the InventoryEntry after the quantity was updated.@NotNull Long
Available quantity for the InventoryEntry before the quantity was updated.@NotNull Long
Quantity on stock for the InventoryEntry before the quantity was updated.@Valid ChannelReference
Reference to the Channel where the InventoryEntry quantity was set.of()
factory methodof
(InventoryEntryQuantitySetMessage template) factory method to create a shallow copy InventoryEntryQuantitySetMessagevoid
setNewAvailableQuantity
(Long newAvailableQuantity) Available quantity for the InventoryEntry after the quantity was updated.void
setNewQuantityOnStock
(Long newQuantityOnStock) Quantity on stock for the InventoryEntry after the quantity was updated.void
setOldAvailableQuantity
(Long oldAvailableQuantity) Available quantity for the InventoryEntry before the quantity was updated.void
setOldQuantityOnStock
(Long oldQuantityOnStock) Quantity on stock for the InventoryEntry before the quantity was updated.void
setSupplyChannel
(ChannelReference supplyChannel) Reference to the Channel where the InventoryEntry quantity was set.static com.fasterxml.jackson.core.type.TypeReference<InventoryEntryQuantitySetMessage>
gives a TypeReference for usage with Jackson DataBinddefault <T> T
accessor map functionMethods inherited from interface com.commercetools.api.models.common.BaseResource
withBaseResource
Methods inherited from interface com.commercetools.api.models.DomainResource
get
Methods inherited from interface com.commercetools.api.models.message.Message
getCreatedAt, getCreatedBy, getId, getLastModifiedAt, getLastModifiedBy, getResource, getResourceUserProvidedIdentifiers, getResourceVersion, getSequenceNumber, getType, getVersion, setCreatedAt, setCreatedBy, setId, setLastModifiedAt, setLastModifiedBy, setResource, setResourceUserProvidedIdentifiers, setResourceVersion, setSequenceNumber, setVersion, withMessage
-
Field Details
-
INVENTORY_ENTRY_QUANTITY_SET
discriminator value for InventoryEntryQuantitySetMessage- See Also:
-
-
Method Details
-
getOldQuantityOnStock
Quantity on stock for the InventoryEntry before the quantity was updated.
- Returns:
- oldQuantityOnStock
-
getNewQuantityOnStock
Quantity on stock for the InventoryEntry after the quantity was updated.
- Returns:
- newQuantityOnStock
-
getOldAvailableQuantity
Available quantity for the InventoryEntry before the quantity was updated.
- Returns:
- oldAvailableQuantity
-
getNewAvailableQuantity
Available quantity for the InventoryEntry after the quantity was updated.
- Returns:
- newAvailableQuantity
-
getSupplyChannel
Reference to the Channel where the InventoryEntry quantity was set.
- Returns:
- supplyChannel
-
setOldQuantityOnStock
Quantity on stock for the InventoryEntry before the quantity was updated.
- Parameters:
oldQuantityOnStock
- value to be set
-
setNewQuantityOnStock
Quantity on stock for the InventoryEntry after the quantity was updated.
- Parameters:
newQuantityOnStock
- value to be set
-
setOldAvailableQuantity
Available quantity for the InventoryEntry before the quantity was updated.
- Parameters:
oldAvailableQuantity
- value to be set
-
setNewAvailableQuantity
Available quantity for the InventoryEntry after the quantity was updated.
- Parameters:
newAvailableQuantity
- value to be set
-
setSupplyChannel
Reference to the Channel where the InventoryEntry quantity was set.
- Parameters:
supplyChannel
- value to be set
-
of
factory method- Returns:
- instance of InventoryEntryQuantitySetMessage
-
of
factory method to create a shallow copy InventoryEntryQuantitySetMessage- Parameters:
template
- instance to be copied- Returns:
- copy instance
-
deepCopy
@Nullable static InventoryEntryQuantitySetMessage deepCopy(@Nullable InventoryEntryQuantitySetMessage template) factory method to create a deep copy of InventoryEntryQuantitySetMessage- Parameters:
template
- instance to be copied- Returns:
- copy instance
-
builder
builder factory method for InventoryEntryQuantitySetMessage- Returns:
- builder
-
builder
create builder for InventoryEntryQuantitySetMessage instance- Parameters:
template
- instance with prefilled values for the builder- Returns:
- builder
-
withInventoryEntryQuantitySetMessage
default <T> T withInventoryEntryQuantitySetMessage(Function<InventoryEntryQuantitySetMessage, 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<InventoryEntryQuantitySetMessage> typeReference()gives a TypeReference for usage with Jackson DataBind- Returns:
- TypeReference
-