Interface DiscountedTotalPricePortion
public interface DiscountedTotalPricePortion
DiscountedTotalPricePortion
Example to create an instance using the builder pattern
Example to create an instance using the builder pattern
DiscountedTotalPricePortion discountedTotalPricePortion = DiscountedTotalPricePortion.builder()
.discount(discountBuilder -> discountBuilder)
.discountedAmount(discountedAmountBuilder -> discountedAmountBuilder)
.build()
-
Method Summary
Modifier and TypeMethodDescriptionbuilder()
builder factory method for DiscountedTotalPricePortionbuilder
(DiscountedTotalPricePortion template) create builder for DiscountedTotalPricePortion instancestatic DiscountedTotalPricePortion
deepCopy
(DiscountedTotalPricePortion template) factory method to create a deep copy of DiscountedTotalPricePortion@NotNull @Valid CartDiscountReference
Cart Discount related to the discounted price.@NotNull @Valid TypedMoney
Money value of the discount.static DiscountedTotalPricePortion
of()
factory methodstatic DiscountedTotalPricePortion
of
(DiscountedTotalPricePortion template) factory method to create a shallow copy DiscountedTotalPricePortionvoid
setDiscount
(CartDiscountReference discount) Cart Discount related to the discounted price.void
setDiscountedAmount
(TypedMoney discountedAmount) Money value of the discount.static com.fasterxml.jackson.core.type.TypeReference<DiscountedTotalPricePortion>
gives a TypeReference for usage with Jackson DataBinddefault <T> T
accessor map function
-
Method Details
-
getDiscount
Cart Discount related to the discounted price.
- Returns:
- discount
-
getDiscountedAmount
Money value of the discount.
- Returns:
- discountedAmount
-
setDiscount
Cart Discount related to the discounted price.
- Parameters:
discount
- value to be set
-
setDiscountedAmount
Money value of the discount.
- Parameters:
discountedAmount
- value to be set
-
of
factory method- Returns:
- instance of DiscountedTotalPricePortion
-
of
factory method to create a shallow copy DiscountedTotalPricePortion- Parameters:
template
- instance to be copied- Returns:
- copy instance
-
deepCopy
@Nullable static DiscountedTotalPricePortion deepCopy(@Nullable DiscountedTotalPricePortion template) factory method to create a deep copy of DiscountedTotalPricePortion- Parameters:
template
- instance to be copied- Returns:
- copy instance
-
builder
builder factory method for DiscountedTotalPricePortion- Returns:
- builder
-
builder
create builder for DiscountedTotalPricePortion instance- Parameters:
template
- instance with prefilled values for the builder- Returns:
- builder
-
withDiscountedTotalPricePortion
accessor map function- Type Parameters:
T
- mapped type- Parameters:
helper
- function to map the object- Returns:
- mapped value
-
typeReference
gives a TypeReference for usage with Jackson DataBind- Returns:
- TypeReference
-