Class ProductDiscountValueBuilder
java.lang.Object
com.commercetools.history.models.common.ProductDiscountValueBuilder
- All Implemented Interfaces:
Builder<ProductDiscountValue>
ProductDiscountValueBuilder
Example to create an instance using the builder pattern
Example to create an instance using the builder pattern
ProductDiscountValue productDiscountValue = ProductDiscountValue.builder()
.type("{type}")
.build()
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()builds ProductDiscountValue with checking for non-null required valuesbuilds ProductDiscountValue without checking for non-null required valuesgetType()value of type}static ProductDiscountValueBuilderof()factory method for an instance of ProductDiscountValueBuilderstatic ProductDiscountValueBuilderof(ProductDiscountValue template) create builder for ProductDiscountValue instanceset the value to the type
-
Constructor Details
-
ProductDiscountValueBuilder
public ProductDiscountValueBuilder()
-
-
Method Details
-
type
set the value to the type- Parameters:
type- value to be set- Returns:
- Builder
-
getType
value of type}- Returns:
- type
-
build
builds ProductDiscountValue with checking for non-null required values- Specified by:
buildin interfaceBuilder<ProductDiscountValue>- Returns:
- ProductDiscountValue
-
buildUnchecked
builds ProductDiscountValue without checking for non-null required values- Returns:
- ProductDiscountValue
-
of
factory method for an instance of ProductDiscountValueBuilder- Returns:
- builder
-
of
create builder for ProductDiscountValue instance- Parameters:
template- instance with prefilled values for the builder- Returns:
- builder
-