Class ProductImpl
- All Implemented Interfaces:
BaseResource
,DomainResource<Product>
,Identifiable<Product>
,Product
,ProductMixin
,Referencable<Product>
,ResourceIdentifiable<Product>
,Versioned<Product>
,WithKey
,io.vrap.rmf.base.client.ModelBase
An abstract sellable good with a set of Attributes defined by a Product Type. Products themselves are not sellable. Instead, they act as a parent structure for Product Variants. Each Product must have at least one Product Variant, which is called the Master Variant. A single Product representation contains the current and the staged representation of its product data.
-
Nested Class Summary
Nested classes/interfaces inherited from interface io.vrap.rmf.base.client.ModelBase
io.vrap.rmf.base.client.ModelBase.FilteredRecursiveToStringStyle
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionboolean
Date and time (UTC) the Product was initially created.Present on resources created after 1 February 2019 except for events not tracked.getId()
Unique identifier of the Product.getKey()
User-defined unique identifier of the Product.Date and time (UTC) the Product was last updated.Present on resources created after 1 February 2019 except for events not tracked.Contains the current and the staged representation of the product information.Type of Price to be used when looking up a price for the Product.The Product Type defining the Attributes of the Product.Review statistics of the Product.getState()
State of the Product.The TaxCategory of the Product.Current version of the Product.int
hashCode()
void
setCreatedAt
(ZonedDateTime createdAt) Date and time (UTC) the Product was initially created.void
setCreatedBy
(CreatedBy createdBy) Present on resources created after 1 February 2019 except for events not tracked.void
Unique identifier of the Product.void
User-defined unique identifier of the Product.void
setLastModifiedAt
(ZonedDateTime lastModifiedAt) Date and time (UTC) the Product was last updated.void
setLastModifiedBy
(LastModifiedBy lastModifiedBy) Present on resources created after 1 February 2019 except for events not tracked.void
setMasterData
(ProductCatalogData masterData) Contains the current and the staged representation of the product information.void
setPriceMode
(ProductPriceModeEnum priceMode) Type of Price to be used when looking up a price for the Product.void
setProductType
(ProductTypeReference productType) The Product Type defining the Attributes of the Product.void
setReviewRatingStatistics
(ReviewRatingStatistics reviewRatingStatistics) Review statistics of the Product.void
setState
(StateReference state) State of the Product.void
setTaxCategory
(TaxCategoryReference taxCategory) The TaxCategory of the Product.void
setVersion
(Long version) Current version of the Product.Methods inherited from class java.lang.Object
getClass, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.commercetools.api.models.common.BaseResource
withBaseResource
Methods inherited from interface com.commercetools.api.models.DomainResource
get
Methods inherited from interface io.vrap.rmf.base.client.ModelBase
reflectionString, reflectionString
Methods inherited from interface com.commercetools.api.models.product.Product
withProduct
Methods inherited from interface com.commercetools.api.models.product.ProductMixin
toReference, toResourceIdentifier
-
Constructor Details
-
ProductImpl
public ProductImpl()create empty instance
-
-
Method Details
-
getId
Unique identifier of the Product.
- Specified by:
getId
in interfaceBaseResource
- Specified by:
getId
in interfaceDomainResource<Product>
- Specified by:
getId
in interfaceIdentifiable<Product>
- Specified by:
getId
in interfaceProduct
- Specified by:
getId
in interfaceVersioned<Product>
- Returns:
- id
-
getVersion
Current version of the Product.
- Specified by:
getVersion
in interfaceBaseResource
- Specified by:
getVersion
in interfaceDomainResource<Product>
- Specified by:
getVersion
in interfaceProduct
- Specified by:
getVersion
in interfaceVersioned<Product>
- Returns:
- version
-
getCreatedAt
Date and time (UTC) the Product was initially created.
- Specified by:
getCreatedAt
in interfaceBaseResource
- Specified by:
getCreatedAt
in interfaceProduct
- Returns:
- createdAt
-
getLastModifiedAt
Date and time (UTC) the Product was last updated.
- Specified by:
getLastModifiedAt
in interfaceBaseResource
- Specified by:
getLastModifiedAt
in interfaceProduct
- Returns:
- lastModifiedAt
-
getLastModifiedBy
Present on resources created after 1 February 2019 except for events not tracked.
- Specified by:
getLastModifiedBy
in interfaceProduct
- Returns:
- lastModifiedBy
-
getCreatedBy
Present on resources created after 1 February 2019 except for events not tracked.
- Specified by:
getCreatedBy
in interfaceProduct
- Returns:
- createdBy
-
getKey
User-defined unique identifier of the Product.
This is different from the
key
of a ProductVariant. -
getProductType
The Product Type defining the Attributes of the Product. Cannot be changed.
- Specified by:
getProductType
in interfaceProduct
- Returns:
- productType
-
getMasterData
Contains the current and the staged representation of the product information.
- Specified by:
getMasterData
in interfaceProduct
- Returns:
- masterData
-
getTaxCategory
The TaxCategory of the Product.
- Specified by:
getTaxCategory
in interfaceProduct
- Returns:
- taxCategory
-
getState
State of the Product.
-
getReviewRatingStatistics
Review statistics of the Product.
- Specified by:
getReviewRatingStatistics
in interfaceProduct
- Returns:
- reviewRatingStatistics
-
getPriceMode
Type of Price to be used when looking up a price for the Product.
- Specified by:
getPriceMode
in interfaceProduct
- Returns:
- priceMode
-
setId
Description copied from interface:Product
Unique identifier of the Product.
- Specified by:
setId
in interfaceBaseResource
- Specified by:
setId
in interfaceProduct
- Parameters:
id
- value to be set
-
setVersion
Description copied from interface:Product
Current version of the Product.
- Specified by:
setVersion
in interfaceBaseResource
- Specified by:
setVersion
in interfaceProduct
- Parameters:
version
- value to be set
-
setCreatedAt
Description copied from interface:Product
Date and time (UTC) the Product was initially created.
- Specified by:
setCreatedAt
in interfaceBaseResource
- Specified by:
setCreatedAt
in interfaceProduct
- Parameters:
createdAt
- value to be set
-
setLastModifiedAt
Description copied from interface:Product
Date and time (UTC) the Product was last updated.
- Specified by:
setLastModifiedAt
in interfaceBaseResource
- Specified by:
setLastModifiedAt
in interfaceProduct
- Parameters:
lastModifiedAt
- value to be set
-
setLastModifiedBy
Description copied from interface:Product
Present on resources created after 1 February 2019 except for events not tracked.
- Specified by:
setLastModifiedBy
in interfaceProduct
- Parameters:
lastModifiedBy
- value to be set
-
setCreatedBy
Description copied from interface:Product
Present on resources created after 1 February 2019 except for events not tracked.
- Specified by:
setCreatedBy
in interfaceProduct
- Parameters:
createdBy
- value to be set
-
setKey
Description copied from interface:Product
User-defined unique identifier of the Product.
This is different from the
key
of a ProductVariant. -
setProductType
Description copied from interface:Product
The Product Type defining the Attributes of the Product. Cannot be changed.
- Specified by:
setProductType
in interfaceProduct
- Parameters:
productType
- value to be set
-
setMasterData
Description copied from interface:Product
Contains the current and the staged representation of the product information.
- Specified by:
setMasterData
in interfaceProduct
- Parameters:
masterData
- value to be set
-
setTaxCategory
Description copied from interface:Product
The TaxCategory of the Product.
- Specified by:
setTaxCategory
in interfaceProduct
- Parameters:
taxCategory
- value to be set
-
setState
Description copied from interface:Product
State of the Product.
-
setReviewRatingStatistics
Description copied from interface:Product
Review statistics of the Product.
- Specified by:
setReviewRatingStatistics
in interfaceProduct
- Parameters:
reviewRatingStatistics
- value to be set
-
setPriceMode
Description copied from interface:Product
Type of Price to be used when looking up a price for the Product.
- Specified by:
setPriceMode
in interfaceProduct
- Parameters:
priceMode
- value to be set
-
equals
-
hashCode
public int hashCode()
-