Class DiscountCodeSetValidFromAndUntilActionBuilder
java.lang.Object
com.commercetools.api.models.discount_code.DiscountCodeSetValidFromAndUntilActionBuilder
- All Implemented Interfaces:
Builder<DiscountCodeSetValidFromAndUntilAction>
public class DiscountCodeSetValidFromAndUntilActionBuilder
extends Object
implements Builder<DiscountCodeSetValidFromAndUntilAction>
DiscountCodeSetValidFromAndUntilActionBuilder
Example to create an instance using the builder pattern
Example to create an instance using the builder pattern
DiscountCodeSetValidFromAndUntilAction discountCodeSetValidFromAndUntilAction = DiscountCodeSetValidFromAndUntilAction.builder()
.build()
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionbuild()
builds DiscountCodeSetValidFromAndUntilAction with checking for non-null required valuesbuilds DiscountCodeSetValidFromAndUntilAction without checking for non-null required valuesValue to set that must be earlier thanvalidUntil
.Value to set that must be later thanvalidFrom
.of()
factory method for an instance of DiscountCodeSetValidFromAndUntilActionBuilderof
(DiscountCodeSetValidFromAndUntilAction template) create builder for DiscountCodeSetValidFromAndUntilAction instancevalidFrom
(ZonedDateTime validFrom) Value to set that must be earlier thanvalidUntil
.validUntil
(ZonedDateTime validUntil) Value to set that must be later thanvalidFrom
.
-
Constructor Details
-
DiscountCodeSetValidFromAndUntilActionBuilder
public DiscountCodeSetValidFromAndUntilActionBuilder()
-
-
Method Details
-
validFrom
Value to set that must be earlier than
validUntil
. If empty, any existing value will be removed.- Parameters:
validFrom
- value to be set- Returns:
- Builder
-
validUntil
Value to set that must be later than
validFrom
. If empty, any existing value will be removed.- Parameters:
validUntil
- value to be set- Returns:
- Builder
-
getValidFrom
Value to set that must be earlier than
validUntil
. If empty, any existing value will be removed.- Returns:
- validFrom
-
getValidUntil
Value to set that must be later than
validFrom
. If empty, any existing value will be removed.- Returns:
- validUntil
-
build
builds DiscountCodeSetValidFromAndUntilAction with checking for non-null required values- Specified by:
build
in interfaceBuilder<DiscountCodeSetValidFromAndUntilAction>
- Returns:
- DiscountCodeSetValidFromAndUntilAction
-
buildUnchecked
builds DiscountCodeSetValidFromAndUntilAction without checking for non-null required values- Returns:
- DiscountCodeSetValidFromAndUntilAction
-
of
factory method for an instance of DiscountCodeSetValidFromAndUntilActionBuilder- Returns:
- builder
-
of
public static DiscountCodeSetValidFromAndUntilActionBuilder of(DiscountCodeSetValidFromAndUntilAction template) create builder for DiscountCodeSetValidFromAndUntilAction instance- Parameters:
template
- instance with prefilled values for the builder- Returns:
- builder
-