Interface AttributeValue
public interface AttributeValue
AttributeValue
Example to create an instance using the builder pattern
Example to create an instance using the builder pattern
AttributeValue attributeValue = AttributeValue.builder()
.name("{name}")
.build()
-
Method Summary
Modifier and TypeMethodDescriptionstatic AttributeValueBuilder
builder()
builder factory method for AttributeValuestatic AttributeValueBuilder
builder
(AttributeValue template) create builder for AttributeValue instancestatic AttributeValue
deepCopy
(AttributeValue template) factory method to create a deep copy of AttributeValue@NotNull String
getName()
Name of the Attribute set.@NotNull Object
getValue()
Value set for the Attribute determined by the AttributeType:static AttributeValue
of()
factory methodstatic AttributeValue
of
(AttributeValue template) factory method to create a shallow copy AttributeValuevoid
Name of the Attribute set.void
Value set for the Attribute determined by the AttributeType:static com.fasterxml.jackson.core.type.TypeReference<AttributeValue>
gives a TypeReference for usage with Jackson DataBinddefault <T> T
withAttributeValue
(Function<AttributeValue, T> helper) accessor map function
-
Method Details
-
getName
Name of the Attribute set.
- Returns:
- name
-
getValue
Value set for the Attribute determined by the AttributeType:
- For Enum Type and Localized Enum Type,
value
is thekey
of the Plain Enum Value or Localized Enum Value objects, or the complete objects. - For Localizable Text Type,
value
is the LocalizedString object. - For Money Type Attributes,
value
is the Money object. - For Set Type Attributes,
value
is the entireset
object. - For Nested Type Attributes,
value
is the list of values of all Attributes of the nested Product. - For Reference Type Attributes,
value
is the Reference object.
- Returns:
- value
- For Enum Type and Localized Enum Type,
-
setName
Name of the Attribute set.
- Parameters:
name
- value to be set
-
setValue
Value set for the Attribute determined by the AttributeType:
- For Enum Type and Localized Enum Type,
value
is thekey
of the Plain Enum Value or Localized Enum Value objects, or the complete objects. - For Localizable Text Type,
value
is the LocalizedString object. - For Money Type Attributes,
value
is the Money object. - For Set Type Attributes,
value
is the entireset
object. - For Nested Type Attributes,
value
is the list of values of all Attributes of the nested Product. - For Reference Type Attributes,
value
is the Reference object.
- Parameters:
value
- value to be set
- For Enum Type and Localized Enum Type,
-
of
factory method- Returns:
- instance of AttributeValue
-
of
factory method to create a shallow copy AttributeValue- Parameters:
template
- instance to be copied- Returns:
- copy instance
-
deepCopy
factory method to create a deep copy of AttributeValue- Parameters:
template
- instance to be copied- Returns:
- copy instance
-
builder
builder factory method for AttributeValue- Returns:
- builder
-
builder
create builder for AttributeValue instance- Parameters:
template
- instance with prefilled values for the builder- Returns:
- builder
-
withAttributeValue
accessor map function- Type Parameters:
T
- mapped type- Parameters:
helper
- function to map the object- Returns:
- mapped value
-
typeReference
gives a TypeReference for usage with Jackson DataBind- Returns:
- TypeReference
-