Interface CartDiscountCustomLineItemsTarget
- All Superinterfaces:
CartDiscountTarget
- All Known Implementing Classes:
CartDiscountCustomLineItemsTargetImpl
Discount is applied to CustomLineItems matching the predicate
.
Example to create an instance using the builder pattern
CartDiscountCustomLineItemsTarget cartDiscountCustomLineItemsTarget = CartDiscountCustomLineItemsTarget.builder()
.predicate("{predicate}")
.build()
-
Field Summary
Modifier and TypeFieldDescriptionstatic final String
discriminator value for CartDiscountCustomLineItemsTarget -
Method Summary
Modifier and TypeMethodDescriptionbuilder()
builder factory method for CartDiscountCustomLineItemsTargetbuilder
(CartDiscountCustomLineItemsTarget template) create builder for CartDiscountCustomLineItemsTarget instancedeepCopy
(CartDiscountCustomLineItemsTarget template) factory method to create a deep copy of CartDiscountCustomLineItemsTarget@NotNull String
Valid CustomLineItem target predicate.of()
factory methodof
(CartDiscountCustomLineItemsTarget template) factory method to create a shallow copy CartDiscountCustomLineItemsTargetvoid
setPredicate
(String predicate) Valid CustomLineItem target predicate.static com.fasterxml.jackson.core.type.TypeReference<CartDiscountCustomLineItemsTarget>
gives a TypeReference for usage with Jackson DataBinddefault <T> T
accessor map functionMethods inherited from interface com.commercetools.api.models.cart_discount.CartDiscountTarget
getType, withCartDiscountTarget
-
Field Details
-
CUSTOM_LINE_ITEMS
discriminator value for CartDiscountCustomLineItemsTarget- See Also:
-
-
Method Details
-
getPredicate
Valid CustomLineItem target predicate.
- Returns:
- predicate
-
setPredicate
Valid CustomLineItem target predicate.
- Parameters:
predicate
- value to be set
-
of
factory method- Returns:
- instance of CartDiscountCustomLineItemsTarget
-
of
factory method to create a shallow copy CartDiscountCustomLineItemsTarget- Parameters:
template
- instance to be copied- Returns:
- copy instance
-
deepCopy
@Nullable static CartDiscountCustomLineItemsTarget deepCopy(@Nullable CartDiscountCustomLineItemsTarget template) factory method to create a deep copy of CartDiscountCustomLineItemsTarget- Parameters:
template
- instance to be copied- Returns:
- copy instance
-
builder
builder factory method for CartDiscountCustomLineItemsTarget- Returns:
- builder
-
builder
create builder for CartDiscountCustomLineItemsTarget instance- Parameters:
template
- instance with prefilled values for the builder- Returns:
- builder
-
withCartDiscountCustomLineItemsTarget
default <T> T withCartDiscountCustomLineItemsTarget(Function<CartDiscountCustomLineItemsTarget, 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<CartDiscountCustomLineItemsTarget> typeReference()gives a TypeReference for usage with Jackson DataBind- Returns:
- TypeReference
-