Interface ProductSetProductAttributeAction
- All Superinterfaces:
ProductUpdateAction,ResourceUpdateAction<ProductUpdateAction>
ProductSetProductAttributeAction
Example to create an instance using the builder pattern
Example to create an instance using the builder pattern
ProductSetProductAttributeAction productSetProductAttributeAction = ProductSetProductAttributeAction.builder()
.name("{name}")
.build()
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Stringdiscriminator value for ProductSetProductAttributeAction -
Method Summary
Modifier and TypeMethodDescriptionbuilder()builder factory method for ProductSetProductAttributeActionbuilder(ProductSetProductAttributeAction template) create builder for ProductSetProductAttributeAction instancecopyDeep()deepCopy(ProductSetProductAttributeAction template) factory method to create a deep copy of ProductSetProductAttributeAction@NotNull StringgetName()Name of the Product Attribute to set.Iftrue, only the staged Attribute is set.getValue()Value to set for the Attribute.of()factory methodof(ProductSetProductAttributeAction template) factory method to create a shallow copy ProductSetProductAttributeActionvoidName of the Product Attribute to set.voidIftrue, only the staged Attribute is set.voidValue to set for the Attribute.static com.fasterxml.jackson.core.type.TypeReference<ProductSetProductAttributeAction>gives a TypeReference for usage with Jackson DataBinddefault <T> Taccessor map functionMethods inherited from interface com.commercetools.api.models.product.ProductUpdateAction
getAction, withProductUpdateActionMethods inherited from interface com.commercetools.api.models.ResourceUpdateAction
get
-
Field Details
-
SET_PRODUCT_ATTRIBUTE
discriminator value for ProductSetProductAttributeAction- See Also:
-
-
Method Details
-
getName
Name of the Product Attribute to set.
- Returns:
- name
-
getValue
Object getValue()Value to set for the Attribute. If empty, any existing value will be removed.
The AttributeType determines the format of the Attribute
valueto be provided:- For Enum Type and Localized Enum Type, use the
keyof the Plain Enum Value or Localized Enum Value object or the complete object asvalue. - For Localizable Text Type, use the LocalizedString object as
value. - For Money Type Attributes, use the Money object as
value. - For Set Type Attributes, use the entire
setobject asvalue. - For Nested Type Attributes, use the list of values of all Attributes of the nested Product as
value. - For Reference Type Attributes, use the Reference object as
value.
- Returns:
- value
- For Enum Type and Localized Enum Type, use the
-
getStaged
Boolean getStaged()If
true, only the staged Attribute is set. Iffalse, both the current and staged Attributes are set.- Returns:
- staged
-
setName
Name of the Product Attribute to set.
- Parameters:
name- value to be set
-
setValue
Value to set for the Attribute. If empty, any existing value will be removed.
The AttributeType determines the format of the Attribute
valueto be provided:- For Enum Type and Localized Enum Type, use the
keyof the Plain Enum Value or Localized Enum Value object or the complete object asvalue. - For Localizable Text Type, use the LocalizedString object as
value. - For Money Type Attributes, use the Money object as
value. - For Set Type Attributes, use the entire
setobject asvalue. - For Nested Type Attributes, use the list of values of all Attributes of the nested Product as
value. - For Reference Type Attributes, use the Reference object as
value.
- Parameters:
value- value to be set
- For Enum Type and Localized Enum Type, use the
-
setStaged
If
true, only the staged Attribute is set. Iffalse, both the current and staged Attributes are set.- Parameters:
staged- value to be set
-
of
factory method- Returns:
- instance of ProductSetProductAttributeAction
-
of
factory method to create a shallow copy ProductSetProductAttributeAction- Parameters:
template- instance to be copied- Returns:
- copy instance
-
copyDeep
ProductSetProductAttributeAction copyDeep()- Specified by:
copyDeepin interfaceProductUpdateAction
-
deepCopy
@Nullable static ProductSetProductAttributeAction deepCopy(@Nullable ProductSetProductAttributeAction template) factory method to create a deep copy of ProductSetProductAttributeAction- Parameters:
template- instance to be copied- Returns:
- copy instance
-
builder
builder factory method for ProductSetProductAttributeAction- Returns:
- builder
-
builder
create builder for ProductSetProductAttributeAction instance- Parameters:
template- instance with prefilled values for the builder- Returns:
- builder
-
withProductSetProductAttributeAction
default <T> T withProductSetProductAttributeAction(Function<ProductSetProductAttributeAction, 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<ProductSetProductAttributeAction> typeReference()gives a TypeReference for usage with Jackson DataBind- Returns:
- TypeReference
-