Class ProductAddPriceActionImpl
java.lang.Object
com.commercetools.api.models.product.ProductAddPriceActionImpl
- All Implemented Interfaces:
ProductAddPriceAction
,ProductUpdateAction
,ResourceUpdateAction<ProductUpdateAction>
,io.vrap.rmf.base.client.ModelBase
public class ProductAddPriceActionImpl
extends Object
implements ProductAddPriceAction, io.vrap.rmf.base.client.ModelBase
Adds the given Price to the prices
array of the ProductVariant. Either variantId
or sku
is required.
-
Nested Class Summary
Nested classes/interfaces inherited from interface io.vrap.rmf.base.client.ModelBase
io.vrap.rmf.base.client.ModelBase.FilteredRecursiveToStringStyle
-
Field Summary
Fields inherited from interface com.commercetools.api.models.product.ProductAddPriceAction
ADD_PRICE
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionboolean
getPrice()
Embedded Price to add to the Product Variant.getSku()
Thesku
of the ProductVariant to update.Iftrue
, only the stagedprices
is updated.Theid
of the ProductVariant to update.int
hashCode()
void
setPrice
(PriceDraft price) Embedded Price to add to the Product Variant.void
Thesku
of the ProductVariant to update.void
Iftrue
, only the stagedprices
is updated.void
setVariantId
(Long variantId) Theid
of the ProductVariant to update.Methods inherited from class java.lang.Object
getClass, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface io.vrap.rmf.base.client.ModelBase
reflectionString, reflectionString
Methods inherited from interface com.commercetools.api.models.product.ProductAddPriceAction
withProductAddPriceAction
Methods inherited from interface com.commercetools.api.models.product.ProductUpdateAction
withProductUpdateAction
Methods inherited from interface com.commercetools.api.models.ResourceUpdateAction
get
-
Constructor Details
-
ProductAddPriceActionImpl
public ProductAddPriceActionImpl()create empty instance
-
-
Method Details
-
getAction
- Specified by:
getAction
in interfaceProductUpdateAction
- Specified by:
getAction
in interfaceResourceUpdateAction<ProductUpdateAction>
- Returns:
- action
-
getVariantId
The
id
of the ProductVariant to update.- Specified by:
getVariantId
in interfaceProductAddPriceAction
- Returns:
- variantId
-
getSku
The
sku
of the ProductVariant to update.- Specified by:
getSku
in interfaceProductAddPriceAction
- Returns:
- sku
-
getPrice
Embedded Price to add to the Product Variant.
- Specified by:
getPrice
in interfaceProductAddPriceAction
- Returns:
- price
-
getStaged
If
true
, only the stagedprices
is updated. Iffalse
, both the current and stagedprices
are updated.- Specified by:
getStaged
in interfaceProductAddPriceAction
- Returns:
- staged
-
setVariantId
Description copied from interface:ProductAddPriceAction
The
id
of the ProductVariant to update.- Specified by:
setVariantId
in interfaceProductAddPriceAction
- Parameters:
variantId
- value to be set
-
setSku
Description copied from interface:ProductAddPriceAction
The
sku
of the ProductVariant to update.- Specified by:
setSku
in interfaceProductAddPriceAction
- Parameters:
sku
- value to be set
-
setPrice
Description copied from interface:ProductAddPriceAction
Embedded Price to add to the Product Variant.
- Specified by:
setPrice
in interfaceProductAddPriceAction
- Parameters:
price
- value to be set
-
setStaged
Description copied from interface:ProductAddPriceAction
If
true
, only the stagedprices
is updated. Iffalse
, both the current and stagedprices
are updated.- Specified by:
setStaged
in interfaceProductAddPriceAction
- Parameters:
staged
- value to be set
-
equals
-
hashCode
public int hashCode()
-