Interface OrderDiscountCodeAddedMessagePayload
- All Superinterfaces:
MessagePayload
,MessagePayloadMixin
,OrderMessagePayload
Generated after a successful Add DiscountCode update action.
Example to create an instance using the builder pattern
OrderDiscountCodeAddedMessagePayload orderDiscountCodeAddedMessagePayload = OrderDiscountCodeAddedMessagePayload.builder()
.discountCode(discountCodeBuilder -> discountCodeBuilder)
.build()
-
Field Summary
Modifier and TypeFieldDescriptionstatic final String
discriminator value for OrderDiscountCodeAddedMessagePayload -
Method Summary
Modifier and TypeMethodDescriptionbuilder()
builder factory method for OrderDiscountCodeAddedMessagePayloadbuilder
(OrderDiscountCodeAddedMessagePayload template) create builder for OrderDiscountCodeAddedMessagePayload instancedeepCopy
(OrderDiscountCodeAddedMessagePayload template) factory method to create a deep copy of OrderDiscountCodeAddedMessagePayload@NotNull @Valid DiscountCodeReference
DiscountCode that was added.of()
factory methodof
(OrderDiscountCodeAddedMessagePayload template) factory method to create a shallow copy OrderDiscountCodeAddedMessagePayloadvoid
setDiscountCode
(DiscountCodeReference discountCode) DiscountCode that was added.static com.fasterxml.jackson.core.type.TypeReference<OrderDiscountCodeAddedMessagePayload>
gives a TypeReference for usage with Jackson DataBinddefault <T> T
accessor map functionMethods inherited from interface com.commercetools.api.models.message.MessagePayload
getType, withMessagePayload
Methods inherited from interface com.commercetools.api.models.message.MessagePayloadMixin
as
Methods inherited from interface com.commercetools.api.models.message.OrderMessagePayload
withOrderMessagePayload
-
Field Details
-
ORDER_DISCOUNT_CODE_ADDED
discriminator value for OrderDiscountCodeAddedMessagePayload- See Also:
-
-
Method Details
-
getDiscountCode
DiscountCode that was added.
- Returns:
- discountCode
-
setDiscountCode
DiscountCode that was added.
- Parameters:
discountCode
- value to be set
-
of
factory method- Returns:
- instance of OrderDiscountCodeAddedMessagePayload
-
of
factory method to create a shallow copy OrderDiscountCodeAddedMessagePayload- Parameters:
template
- instance to be copied- Returns:
- copy instance
-
deepCopy
@Nullable static OrderDiscountCodeAddedMessagePayload deepCopy(@Nullable OrderDiscountCodeAddedMessagePayload template) factory method to create a deep copy of OrderDiscountCodeAddedMessagePayload- Parameters:
template
- instance to be copied- Returns:
- copy instance
-
builder
builder factory method for OrderDiscountCodeAddedMessagePayload- Returns:
- builder
-
builder
static OrderDiscountCodeAddedMessagePayloadBuilder builder(OrderDiscountCodeAddedMessagePayload template) create builder for OrderDiscountCodeAddedMessagePayload instance- Parameters:
template
- instance with prefilled values for the builder- Returns:
- builder
-
withOrderDiscountCodeAddedMessagePayload
default <T> T withOrderDiscountCodeAddedMessagePayload(Function<OrderDiscountCodeAddedMessagePayload, 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<OrderDiscountCodeAddedMessagePayload> typeReference()gives a TypeReference for usage with Jackson DataBind- Returns:
- TypeReference
-