Class ProductVariantAvailabilityImpl
java.lang.Object
com.commercetools.api.models.product.ProductVariantAvailabilityImpl
- All Implemented Interfaces:
ProductVariantAvailability
,io.vrap.rmf.base.client.ModelBase
public class ProductVariantAvailabilityImpl
extends Object
implements ProductVariantAvailability, io.vrap.rmf.base.client.ModelBase
The InventoryEntry information of the Product Variant. If there is a supply Channel for the InventoryEntry, then channels
is returned. If not, then isOnStock
, restockableInDays
, and quantityOnStock
are returned.
-
Nested Class Summary
Nested classes/interfaces inherited from interface io.vrap.rmf.base.client.ModelBase
io.vrap.rmf.base.client.ModelBase.FilteredRecursiveToStringStyle
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionboolean
Number of items of the Product Variant that are in stock.For each InventoryEntry with a supply Channel, an entry is added tochannels
.Indicates whether a Product Variant is in stock.Number of days to restock a Product Variant once it is out of stock.int
hashCode()
void
setAvailableQuantity
(Long availableQuantity) Number of items of the Product Variant that are in stock.void
For each InventoryEntry with a supply Channel, an entry is added tochannels
.void
setIsOnStock
(Boolean isOnStock) Indicates whether a Product Variant is in stock.void
setRestockableInDays
(Long restockableInDays) Number of days to restock a Product Variant once it is out of stock.toString()
Methods inherited from interface io.vrap.rmf.base.client.ModelBase
reflectionString, reflectionString
Methods inherited from interface com.commercetools.api.models.product.ProductVariantAvailability
withProductVariantAvailability
-
Constructor Details
-
ProductVariantAvailabilityImpl
public ProductVariantAvailabilityImpl()create empty instance
-
-
Method Details
-
getChannels
For each InventoryEntry with a supply Channel, an entry is added to
channels
.- Specified by:
getChannels
in interfaceProductVariantAvailability
- Returns:
- channels
-
getIsOnStock
Indicates whether a Product Variant is in stock.
- Specified by:
getIsOnStock
in interfaceProductVariantAvailability
- Returns:
- isOnStock
-
getRestockableInDays
Number of days to restock a Product Variant once it is out of stock.
- Specified by:
getRestockableInDays
in interfaceProductVariantAvailability
- Returns:
- restockableInDays
-
getAvailableQuantity
Number of items of the Product Variant that are in stock.
- Specified by:
getAvailableQuantity
in interfaceProductVariantAvailability
- Returns:
- availableQuantity
-
setChannels
Description copied from interface:ProductVariantAvailability
For each InventoryEntry with a supply Channel, an entry is added to
channels
.- Specified by:
setChannels
in interfaceProductVariantAvailability
- Parameters:
channels
- value to be set
-
setIsOnStock
Description copied from interface:ProductVariantAvailability
Indicates whether a Product Variant is in stock.
- Specified by:
setIsOnStock
in interfaceProductVariantAvailability
- Parameters:
isOnStock
- value to be set
-
setRestockableInDays
Description copied from interface:ProductVariantAvailability
Number of days to restock a Product Variant once it is out of stock.
- Specified by:
setRestockableInDays
in interfaceProductVariantAvailability
- Parameters:
restockableInDays
- value to be set
-
setAvailableQuantity
Description copied from interface:ProductVariantAvailability
Number of items of the Product Variant that are in stock.
- Specified by:
setAvailableQuantity
in interfaceProductVariantAvailability
- Parameters:
availableQuantity
- value to be set
-
equals
-
hashCode
public int hashCode() -
toString
-