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