Interface ProductTypeChangeAttributeConstraintAction
- All Superinterfaces:
ProductTypeUpdateAction
,ResourceUpdateAction<ProductTypeUpdateAction>
- All Known Implementing Classes:
ProductTypeChangeAttributeConstraintActionImpl
Updates the attributeConstraint
of an AttributeDefinition. For now only following changes are supported: SameForAll
to None
and Unique
to None
.
Example to create an instance using the builder pattern
ProductTypeChangeAttributeConstraintAction productTypeChangeAttributeConstraintAction = ProductTypeChangeAttributeConstraintAction.builder()
.attributeName("{attributeName}")
.newValue(AttributeConstraintEnumDraft.NONE)
.build()
-
Field Summary
Modifier and TypeFieldDescriptionstatic final String
discriminator value for ProductTypeChangeAttributeConstraintAction -
Method Summary
Modifier and TypeMethodDescriptionbuilder()
builder factory method for ProductTypeChangeAttributeConstraintActioncreate builder for ProductTypeChangeAttributeConstraintAction instancefactory method to create a deep copy of ProductTypeChangeAttributeConstraintAction@NotNull String
Name of the AttributeDefinition to update.@NotNull AttributeConstraintEnumDraft
None
of()
factory methodof
(ProductTypeChangeAttributeConstraintAction template) factory method to create a shallow copy ProductTypeChangeAttributeConstraintActionvoid
setAttributeName
(String attributeName) Name of the AttributeDefinition to update.void
setNewValue
(AttributeConstraintEnumDraft newValue) None
static com.fasterxml.jackson.core.type.TypeReference<ProductTypeChangeAttributeConstraintAction>
gives a TypeReference for usage with Jackson DataBinddefault <T> T
withProductTypeChangeAttributeConstraintAction
(Function<ProductTypeChangeAttributeConstraintAction, T> helper) accessor map functionMethods inherited from interface com.commercetools.api.models.product_type.ProductTypeUpdateAction
getAction, withProductTypeUpdateAction
Methods inherited from interface com.commercetools.api.models.ResourceUpdateAction
get
-
Field Details
-
CHANGE_ATTRIBUTE_CONSTRAINT
discriminator value for ProductTypeChangeAttributeConstraintAction- See Also:
-
-
Method Details
-
getAttributeName
Name of the AttributeDefinition to update.
- Returns:
- attributeName
-
getNewValue
None
- Returns:
- newValue
-
setAttributeName
Name of the AttributeDefinition to update.
- Parameters:
attributeName
- value to be set
-
setNewValue
None
- Parameters:
newValue
- value to be set
-
of
factory method- Returns:
- instance of ProductTypeChangeAttributeConstraintAction
-
of
static ProductTypeChangeAttributeConstraintAction of(ProductTypeChangeAttributeConstraintAction template) factory method to create a shallow copy ProductTypeChangeAttributeConstraintAction- Parameters:
template
- instance to be copied- Returns:
- copy instance
-
deepCopy
@Nullable static ProductTypeChangeAttributeConstraintAction deepCopy(@Nullable ProductTypeChangeAttributeConstraintAction template) factory method to create a deep copy of ProductTypeChangeAttributeConstraintAction- Parameters:
template
- instance to be copied- Returns:
- copy instance
-
builder
builder factory method for ProductTypeChangeAttributeConstraintAction- Returns:
- builder
-
builder
static ProductTypeChangeAttributeConstraintActionBuilder builder(ProductTypeChangeAttributeConstraintAction template) create builder for ProductTypeChangeAttributeConstraintAction instance- Parameters:
template
- instance with prefilled values for the builder- Returns:
- builder
-
withProductTypeChangeAttributeConstraintAction
default <T> T withProductTypeChangeAttributeConstraintAction(Function<ProductTypeChangeAttributeConstraintAction, 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<ProductTypeChangeAttributeConstraintAction> typeReference()gives a TypeReference for usage with Jackson DataBind- Returns:
- TypeReference
-