Interface ProductTypeDraft
- All Superinterfaces:
io.vrap.rmf.base.client.Draft<ProductTypeDraft>
,WithKey
- All Known Implementing Classes:
ProductTypeDraftImpl
ProductTypeDraft
Example to create an instance using the builder pattern
Example to create an instance using the builder pattern
ProductTypeDraft productTypeDraft = ProductTypeDraft.builder()
.name("{name}")
.description("{description}")
.build()
-
Method Summary
Modifier and TypeMethodDescriptionstatic ProductTypeDraftBuilder
builder()
builder factory method for ProductTypeDraftstatic ProductTypeDraftBuilder
builder
(ProductTypeDraft template) create builder for ProductTypeDraft instancestatic ProductTypeDraft
deepCopy
(ProductTypeDraft template) factory method to create a deep copy of ProductTypeDraft@Valid List<AttributeDefinitionDraft>
Attributes to specify for the ProductType.@NotNull String
Description of the ProductType.getKey()
User-defined unique identifier for the ProductType.@NotNull String
getName()
Name of the ProductType.static ProductTypeDraft
of()
factory methodstatic ProductTypeDraft
of
(ProductTypeDraft template) factory method to create a shallow copy ProductTypeDraftvoid
setAttributes
(AttributeDefinitionDraft... attributes) Attributes to specify for the ProductType.void
setAttributes
(List<AttributeDefinitionDraft> attributes) Attributes to specify for the ProductType.void
setDescription
(String description) Description of the ProductType.void
User-defined unique identifier for the ProductType.void
Name of the ProductType.static com.fasterxml.jackson.core.type.TypeReference<ProductTypeDraft>
gives a TypeReference for usage with Jackson DataBinddefault <T> T
withProductTypeDraft
(Function<ProductTypeDraft, T> helper) accessor map function
-
Method Details
-
getKey
String getKey()User-defined unique identifier for the ProductType.
-
getName
Name of the ProductType.
- Returns:
- name
-
getDescription
Description of the ProductType.
- Returns:
- description
-
getAttributes
Attributes to specify for the ProductType. Products of this ProductType have these Attributes available on their ProductVariants.
- Returns:
- attributes
-
setKey
User-defined unique identifier for the ProductType.
- Parameters:
key
- value to be set
-
setName
Name of the ProductType.
- Parameters:
name
- value to be set
-
setDescription
Description of the ProductType.
- Parameters:
description
- value to be set
-
setAttributes
Attributes to specify for the ProductType. Products of this ProductType have these Attributes available on their ProductVariants.
- Parameters:
attributes
- values to be set
-
setAttributes
Attributes to specify for the ProductType. Products of this ProductType have these Attributes available on their ProductVariants.
- Parameters:
attributes
- values to be set
-
of
factory method- Returns:
- instance of ProductTypeDraft
-
of
factory method to create a shallow copy ProductTypeDraft- Parameters:
template
- instance to be copied- Returns:
- copy instance
-
deepCopy
factory method to create a deep copy of ProductTypeDraft- Parameters:
template
- instance to be copied- Returns:
- copy instance
-
builder
builder factory method for ProductTypeDraft- Returns:
- builder
-
builder
create builder for ProductTypeDraft instance- Parameters:
template
- instance with prefilled values for the builder- Returns:
- builder
-
withProductTypeDraft
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
-