Interface CartDiscountSetValidFromAndUntilAction
- All Superinterfaces:
CartDiscountUpdateAction
,ResourceUpdateAction<CartDiscountUpdateAction>
CartDiscountSetValidFromAndUntilAction
Example to create an instance using the builder pattern
Example to create an instance using the builder pattern
CartDiscountSetValidFromAndUntilAction cartDiscountSetValidFromAndUntilAction = CartDiscountSetValidFromAndUntilAction.builder()
.build()
-
Field Summary
Modifier and TypeFieldDescriptionstatic final String
discriminator value for CartDiscountSetValidFromAndUntilAction -
Method Summary
Modifier and TypeMethodDescriptionbuilder()
builder factory method for CartDiscountSetValidFromAndUntilActioncreate builder for CartDiscountSetValidFromAndUntilAction instancefactory method to create a deep copy of CartDiscountSetValidFromAndUntilActionValue to set.Value to set.of()
factory methodof
(CartDiscountSetValidFromAndUntilAction template) factory method to create a shallow copy CartDiscountSetValidFromAndUntilActionvoid
setValidFrom
(ZonedDateTime validFrom) Value to set.void
setValidUntil
(ZonedDateTime validUntil) Value to set.static com.fasterxml.jackson.core.type.TypeReference<CartDiscountSetValidFromAndUntilAction>
gives a TypeReference for usage with Jackson DataBinddefault <T> T
withCartDiscountSetValidFromAndUntilAction
(Function<CartDiscountSetValidFromAndUntilAction, T> helper) accessor map functionMethods inherited from interface com.commercetools.api.models.cart_discount.CartDiscountUpdateAction
getAction, withCartDiscountUpdateAction
Methods inherited from interface com.commercetools.api.models.ResourceUpdateAction
get
-
Field Details
-
SET_VALID_FROM_AND_UNTIL
discriminator value for CartDiscountSetValidFromAndUntilAction- See Also:
-
-
Method Details
-
getValidFrom
ZonedDateTime getValidFrom()Value to set. If empty, any existing value will be removed.
- Returns:
- validFrom
-
getValidUntil
ZonedDateTime getValidUntil()Value to set. If empty, any existing value will be removed.
- Returns:
- validUntil
-
setValidFrom
Value to set. If empty, any existing value will be removed.
- Parameters:
validFrom
- value to be set
-
setValidUntil
Value to set. If empty, any existing value will be removed.
- Parameters:
validUntil
- value to be set
-
of
factory method- Returns:
- instance of CartDiscountSetValidFromAndUntilAction
-
of
factory method to create a shallow copy CartDiscountSetValidFromAndUntilAction- Parameters:
template
- instance to be copied- Returns:
- copy instance
-
deepCopy
@Nullable static CartDiscountSetValidFromAndUntilAction deepCopy(@Nullable CartDiscountSetValidFromAndUntilAction template) factory method to create a deep copy of CartDiscountSetValidFromAndUntilAction- Parameters:
template
- instance to be copied- Returns:
- copy instance
-
builder
builder factory method for CartDiscountSetValidFromAndUntilAction- Returns:
- builder
-
builder
static CartDiscountSetValidFromAndUntilActionBuilder builder(CartDiscountSetValidFromAndUntilAction template) create builder for CartDiscountSetValidFromAndUntilAction instance- Parameters:
template
- instance with prefilled values for the builder- Returns:
- builder
-
withCartDiscountSetValidFromAndUntilAction
default <T> T withCartDiscountSetValidFromAndUntilAction(Function<CartDiscountSetValidFromAndUntilAction, T> helper) accessor map function- Type Parameters:
T
- mapped type- Parameters:
helper
- function to map the object- Returns:
- mapped value
-
typeReference
static com.fasterxml.jackson.core.type.TypeReference<CartDiscountSetValidFromAndUntilAction> typeReference()gives a TypeReference for usage with Jackson DataBind- Returns:
- TypeReference
-