Class CustomFieldLocalizedEnumValueBuilder
java.lang.Object
com.commercetools.api.models.type.CustomFieldLocalizedEnumValueBuilder
- All Implemented Interfaces:
Builder<CustomFieldLocalizedEnumValue>
public class CustomFieldLocalizedEnumValueBuilder
extends Object
implements Builder<CustomFieldLocalizedEnumValue>
CustomFieldLocalizedEnumValueBuilder
Example to create an instance using the builder pattern
Example to create an instance using the builder pattern
CustomFieldLocalizedEnumValue customFieldLocalizedEnumValue = CustomFieldLocalizedEnumValue.builder()
.key("{key}")
.label(labelBuilder -> labelBuilder)
.build()
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionbuild()
builds CustomFieldLocalizedEnumValue with checking for non-null required valuesbuilds CustomFieldLocalizedEnumValue without checking for non-null required valuesgetKey()
Key of the value used as a programmatic identifier.getLabel()
Descriptive localized label of the value.Key of the value used as a programmatic identifier.label
(LocalizedString label) Descriptive localized label of the value.Descriptive localized label of the value.of()
factory method for an instance of CustomFieldLocalizedEnumValueBuilderof
(CustomFieldLocalizedEnumValue template) create builder for CustomFieldLocalizedEnumValue instanceDescriptive localized label of the value.
-
Constructor Details
-
CustomFieldLocalizedEnumValueBuilder
public CustomFieldLocalizedEnumValueBuilder()
-
-
Method Details
-
key
Key of the value used as a programmatic identifier.
- Parameters:
key
- value to be set- Returns:
- Builder
-
label
public CustomFieldLocalizedEnumValueBuilder label(Function<LocalizedStringBuilder, LocalizedStringBuilder> builder) Descriptive localized label of the value.
- Parameters:
builder
- function to build the label value- Returns:
- Builder
-
withLabel
public CustomFieldLocalizedEnumValueBuilder withLabel(Function<LocalizedStringBuilder, LocalizedString> builder) Descriptive localized label of the value.
- Parameters:
builder
- function to build the label value- Returns:
- Builder
-
label
Descriptive localized label of the value.
- Parameters:
label
- value to be set- Returns:
- Builder
-
getKey
Key of the value used as a programmatic identifier.
- Returns:
- key
-
getLabel
Descriptive localized label of the value.
- Returns:
- label
-
build
builds CustomFieldLocalizedEnumValue with checking for non-null required values- Specified by:
build
in interfaceBuilder<CustomFieldLocalizedEnumValue>
- Returns:
- CustomFieldLocalizedEnumValue
-
buildUnchecked
builds CustomFieldLocalizedEnumValue without checking for non-null required values- Returns:
- CustomFieldLocalizedEnumValue
-
of
factory method for an instance of CustomFieldLocalizedEnumValueBuilder- Returns:
- builder
-
of
create builder for CustomFieldLocalizedEnumValue instance- Parameters:
template
- instance with prefilled values for the builder- Returns:
- builder
-