Class VariantAttributesAttributeMetadataBuilder
- All Implemented Interfaces:
Builder<VariantAttributesAttributeMetadata>
Example to create an instance using the builder pattern
VariantAttributesAttributeMetadata variantAttributesAttributeMetadata = VariantAttributesAttributeMetadata.builder()
.name("{name}")
.label(labelBuilder -> labelBuilder)
.type("{type}")
.build()
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()builds VariantAttributesAttributeMetadata with checking for non-null required valuesbuilds VariantAttributesAttributeMetadata without checking for non-null required valuesgetLabel()Localized label of the Attribute as defined in the ProductType.getName()Name of the Attribute as defined in the ProductType.getType()Name of the AttributeType, for exampleboolean,text,ltext,enum,lenum,number,money,date,time,datetime,reference,set, ornested.label(LocalizedString label) Localized label of the Attribute as defined in the ProductType.Localized label of the Attribute as defined in the ProductType.Name of the Attribute as defined in the ProductType.of()factory method for an instance of VariantAttributesAttributeMetadataBuilderof(VariantAttributesAttributeMetadata template) create builder for VariantAttributesAttributeMetadata instanceName of the AttributeType, for exampleboolean,text,ltext,enum,lenum,number,money,date,time,datetime,reference,set, ornested.Localized label of the Attribute as defined in the ProductType.
-
Constructor Details
-
VariantAttributesAttributeMetadataBuilder
public VariantAttributesAttributeMetadataBuilder()
-
-
Method Details
-
name
Name of the Attribute as defined in the ProductType.
- Parameters:
name- value to be set- Returns:
- Builder
-
label
public VariantAttributesAttributeMetadataBuilder label(Function<LocalizedStringBuilder, LocalizedStringBuilder> builder) Localized label of the Attribute as defined in the ProductType. Subject to locale projection if
localeProjectionis specified.- Parameters:
builder- function to build the label value- Returns:
- Builder
-
withLabel
public VariantAttributesAttributeMetadataBuilder withLabel(Function<LocalizedStringBuilder, LocalizedString> builder) Localized label of the Attribute as defined in the ProductType. Subject to locale projection if
localeProjectionis specified.- Parameters:
builder- function to build the label value- Returns:
- Builder
-
label
Localized label of the Attribute as defined in the ProductType. Subject to locale projection if
localeProjectionis specified.- Parameters:
label- value to be set- Returns:
- Builder
-
type
Name of the AttributeType, for example
boolean,text,ltext,enum,lenum,number,money,date,time,datetime,reference,set, ornested.- Parameters:
type- value to be set- Returns:
- Builder
-
getName
Name of the Attribute as defined in the ProductType.
- Returns:
- name
-
getLabel
Localized label of the Attribute as defined in the ProductType. Subject to locale projection if
localeProjectionis specified.- Returns:
- label
-
getType
Name of the AttributeType, for example
boolean,text,ltext,enum,lenum,number,money,date,time,datetime,reference,set, ornested.- Returns:
- type
-
build
builds VariantAttributesAttributeMetadata with checking for non-null required values- Specified by:
buildin interfaceBuilder<VariantAttributesAttributeMetadata>- Returns:
- VariantAttributesAttributeMetadata
-
buildUnchecked
builds VariantAttributesAttributeMetadata without checking for non-null required values- Returns:
- VariantAttributesAttributeMetadata
-
of
factory method for an instance of VariantAttributesAttributeMetadataBuilder- Returns:
- builder
-
of
public static VariantAttributesAttributeMetadataBuilder of(VariantAttributesAttributeMetadata template) create builder for VariantAttributesAttributeMetadata instance- Parameters:
template- instance with prefilled values for the builder- Returns:
- builder
-