Class OrderLineItemDiscountSetMessagePayloadBuilder
- All Implemented Interfaces:
Builder<OrderLineItemDiscountSetMessagePayload>
Example to create an instance using the builder pattern
OrderLineItemDiscountSetMessagePayload orderLineItemDiscountSetMessagePayload = OrderLineItemDiscountSetMessagePayload.builder()
.lineItemId("{lineItemId}")
.plusDiscountedPricePerQuantity(discountedPricePerQuantityBuilder -> discountedPricePerQuantityBuilder)
.totalPrice(totalPriceBuilder -> totalPriceBuilder)
.plusTaxedPricePortions(taxedPricePortionsBuilder -> taxedPricePortionsBuilder)
.build()
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionaddDiscountedPricePerQuantity
(Function<DiscountedLineItemPriceForQuantityBuilder, DiscountedLineItemPriceForQuantity> builder) Array of DiscountedLineItemPriceForQuantity after the Discount recalculation.Total taxed prices based on the quantity of Line Item assigned to each Shipping Method.build()
builds OrderLineItemDiscountSetMessagePayload with checking for non-null required valuesbuilds OrderLineItemDiscountSetMessagePayload without checking for non-null required valuesdiscountedPricePerQuantity
(DiscountedLineItemPriceForQuantity... discountedPricePerQuantity) Array of DiscountedLineItemPriceForQuantity after the Discount recalculation.discountedPricePerQuantity
(List<DiscountedLineItemPriceForQuantity> discountedPricePerQuantity) Array of DiscountedLineItemPriceForQuantity after the Discount recalculation.Array of DiscountedLineItemPriceForQuantity after the Discount recalculation.Unique identifier for the Line Item.User-defined unique identifier of the LineItem.TaxedItemPrice of the Line Item after the Discount recalculation.Total taxed prices based on the quantity of Line Item assigned to each Shipping Method.Total Price of the Line Item after the Discount recalculation.lineItemId
(String lineItemId) Unique identifier for the Line Item.lineItemKey
(String lineItemKey) User-defined unique identifier of the LineItem.of()
factory method for an instance of OrderLineItemDiscountSetMessagePayloadBuilderof
(OrderLineItemDiscountSetMessagePayload template) create builder for OrderLineItemDiscountSetMessagePayload instanceplusDiscountedPricePerQuantity
(DiscountedLineItemPriceForQuantity... discountedPricePerQuantity) Array of DiscountedLineItemPriceForQuantity after the Discount recalculation.plusDiscountedPricePerQuantity
(Function<DiscountedLineItemPriceForQuantityBuilder, DiscountedLineItemPriceForQuantityBuilder> builder) Array of DiscountedLineItemPriceForQuantity after the Discount recalculation.plusTaxedPricePortions
(MethodTaxedPrice... taxedPricePortions) Total taxed prices based on the quantity of Line Item assigned to each Shipping Method.Total taxed prices based on the quantity of Line Item assigned to each Shipping Method.setDiscountedPricePerQuantity
(Function<DiscountedLineItemPriceForQuantityBuilder, DiscountedLineItemPriceForQuantity> builder) Array of DiscountedLineItemPriceForQuantity after the Discount recalculation.Total taxed prices based on the quantity of Line Item assigned to each Shipping Method.taxedPrice
(TaxedItemPrice taxedPrice) TaxedItemPrice of the Line Item after the Discount recalculation.TaxedItemPrice of the Line Item after the Discount recalculation.taxedPricePortions
(MethodTaxedPrice... taxedPricePortions) Total taxed prices based on the quantity of Line Item assigned to each Shipping Method.taxedPricePortions
(List<MethodTaxedPrice> taxedPricePortions) Total taxed prices based on the quantity of Line Item assigned to each Shipping Method.totalPrice
(CentPrecisionMoney totalPrice) Total Price of the Line Item after the Discount recalculation.Total Price of the Line Item after the Discount recalculation.withDiscountedPricePerQuantity
(Function<DiscountedLineItemPriceForQuantityBuilder, DiscountedLineItemPriceForQuantityBuilder> builder) Array of DiscountedLineItemPriceForQuantity after the Discount recalculation.TaxedItemPrice of the Line Item after the Discount recalculation.Total taxed prices based on the quantity of Line Item assigned to each Shipping Method.Total Price of the Line Item after the Discount recalculation.
-
Constructor Details
-
OrderLineItemDiscountSetMessagePayloadBuilder
public OrderLineItemDiscountSetMessagePayloadBuilder()
-
-
Method Details
-
lineItemId
Unique identifier for the Line Item.
- Parameters:
lineItemId
- value to be set- Returns:
- Builder
-
lineItemKey
User-defined unique identifier of the LineItem.
- Parameters:
lineItemKey
- value to be set- Returns:
- Builder
-
discountedPricePerQuantity
public OrderLineItemDiscountSetMessagePayloadBuilder discountedPricePerQuantity(DiscountedLineItemPriceForQuantity... discountedPricePerQuantity) Array of DiscountedLineItemPriceForQuantity after the Discount recalculation.
- Parameters:
discountedPricePerQuantity
- value to be set- Returns:
- Builder
-
discountedPricePerQuantity
public OrderLineItemDiscountSetMessagePayloadBuilder discountedPricePerQuantity(List<DiscountedLineItemPriceForQuantity> discountedPricePerQuantity) Array of DiscountedLineItemPriceForQuantity after the Discount recalculation.
- Parameters:
discountedPricePerQuantity
- value to be set- Returns:
- Builder
-
plusDiscountedPricePerQuantity
public OrderLineItemDiscountSetMessagePayloadBuilder plusDiscountedPricePerQuantity(DiscountedLineItemPriceForQuantity... discountedPricePerQuantity) Array of DiscountedLineItemPriceForQuantity after the Discount recalculation.
- Parameters:
discountedPricePerQuantity
- value to be set- Returns:
- Builder
-
plusDiscountedPricePerQuantity
public OrderLineItemDiscountSetMessagePayloadBuilder plusDiscountedPricePerQuantity(Function<DiscountedLineItemPriceForQuantityBuilder, DiscountedLineItemPriceForQuantityBuilder> builder) Array of DiscountedLineItemPriceForQuantity after the Discount recalculation.
- Parameters:
builder
- function to build the discountedPricePerQuantity value- Returns:
- Builder
-
withDiscountedPricePerQuantity
public OrderLineItemDiscountSetMessagePayloadBuilder withDiscountedPricePerQuantity(Function<DiscountedLineItemPriceForQuantityBuilder, DiscountedLineItemPriceForQuantityBuilder> builder) Array of DiscountedLineItemPriceForQuantity after the Discount recalculation.
- Parameters:
builder
- function to build the discountedPricePerQuantity value- Returns:
- Builder
-
addDiscountedPricePerQuantity
public OrderLineItemDiscountSetMessagePayloadBuilder addDiscountedPricePerQuantity(Function<DiscountedLineItemPriceForQuantityBuilder, DiscountedLineItemPriceForQuantity> builder) Array of DiscountedLineItemPriceForQuantity after the Discount recalculation.
- Parameters:
builder
- function to build the discountedPricePerQuantity value- Returns:
- Builder
-
setDiscountedPricePerQuantity
public OrderLineItemDiscountSetMessagePayloadBuilder setDiscountedPricePerQuantity(Function<DiscountedLineItemPriceForQuantityBuilder, DiscountedLineItemPriceForQuantity> builder) Array of DiscountedLineItemPriceForQuantity after the Discount recalculation.
- Parameters:
builder
- function to build the discountedPricePerQuantity value- Returns:
- Builder
-
totalPrice
public OrderLineItemDiscountSetMessagePayloadBuilder totalPrice(Function<CentPrecisionMoneyBuilder, CentPrecisionMoneyBuilder> builder) Total Price of the Line Item after the Discount recalculation.
- Parameters:
builder
- function to build the totalPrice value- Returns:
- Builder
-
withTotalPrice
public OrderLineItemDiscountSetMessagePayloadBuilder withTotalPrice(Function<CentPrecisionMoneyBuilder, CentPrecisionMoney> builder) Total Price of the Line Item after the Discount recalculation.
- Parameters:
builder
- function to build the totalPrice value- Returns:
- Builder
-
totalPrice
Total Price of the Line Item after the Discount recalculation.
- Parameters:
totalPrice
- value to be set- Returns:
- Builder
-
taxedPrice
public OrderLineItemDiscountSetMessagePayloadBuilder taxedPrice(Function<TaxedItemPriceBuilder, TaxedItemPriceBuilder> builder) TaxedItemPrice of the Line Item after the Discount recalculation.
- Parameters:
builder
- function to build the taxedPrice value- Returns:
- Builder
-
withTaxedPrice
public OrderLineItemDiscountSetMessagePayloadBuilder withTaxedPrice(Function<TaxedItemPriceBuilder, TaxedItemPrice> builder) TaxedItemPrice of the Line Item after the Discount recalculation.
- Parameters:
builder
- function to build the taxedPrice value- Returns:
- Builder
-
taxedPrice
public OrderLineItemDiscountSetMessagePayloadBuilder taxedPrice(@Nullable TaxedItemPrice taxedPrice) TaxedItemPrice of the Line Item after the Discount recalculation.
- Parameters:
taxedPrice
- value to be set- Returns:
- Builder
-
taxedPricePortions
public OrderLineItemDiscountSetMessagePayloadBuilder taxedPricePortions(MethodTaxedPrice... taxedPricePortions) Total taxed prices based on the quantity of Line Item assigned to each Shipping Method. Only applicable for Carts with
Multiple
ShippingMode. Automatically set afterperMethodTaxRate
is set.- Parameters:
taxedPricePortions
- value to be set- Returns:
- Builder
-
taxedPricePortions
public OrderLineItemDiscountSetMessagePayloadBuilder taxedPricePortions(List<MethodTaxedPrice> taxedPricePortions) Total taxed prices based on the quantity of Line Item assigned to each Shipping Method. Only applicable for Carts with
Multiple
ShippingMode. Automatically set afterperMethodTaxRate
is set.- Parameters:
taxedPricePortions
- value to be set- Returns:
- Builder
-
plusTaxedPricePortions
public OrderLineItemDiscountSetMessagePayloadBuilder plusTaxedPricePortions(MethodTaxedPrice... taxedPricePortions) Total taxed prices based on the quantity of Line Item assigned to each Shipping Method. Only applicable for Carts with
Multiple
ShippingMode. Automatically set afterperMethodTaxRate
is set.- Parameters:
taxedPricePortions
- value to be set- Returns:
- Builder
-
plusTaxedPricePortions
public OrderLineItemDiscountSetMessagePayloadBuilder plusTaxedPricePortions(Function<MethodTaxedPriceBuilder, MethodTaxedPriceBuilder> builder) Total taxed prices based on the quantity of Line Item assigned to each Shipping Method. Only applicable for Carts with
Multiple
ShippingMode. Automatically set afterperMethodTaxRate
is set.- Parameters:
builder
- function to build the taxedPricePortions value- Returns:
- Builder
-
withTaxedPricePortions
public OrderLineItemDiscountSetMessagePayloadBuilder withTaxedPricePortions(Function<MethodTaxedPriceBuilder, MethodTaxedPriceBuilder> builder) Total taxed prices based on the quantity of Line Item assigned to each Shipping Method. Only applicable for Carts with
Multiple
ShippingMode. Automatically set afterperMethodTaxRate
is set.- Parameters:
builder
- function to build the taxedPricePortions value- Returns:
- Builder
-
addTaxedPricePortions
public OrderLineItemDiscountSetMessagePayloadBuilder addTaxedPricePortions(Function<MethodTaxedPriceBuilder, MethodTaxedPrice> builder) Total taxed prices based on the quantity of Line Item assigned to each Shipping Method. Only applicable for Carts with
Multiple
ShippingMode. Automatically set afterperMethodTaxRate
is set.- Parameters:
builder
- function to build the taxedPricePortions value- Returns:
- Builder
-
setTaxedPricePortions
public OrderLineItemDiscountSetMessagePayloadBuilder setTaxedPricePortions(Function<MethodTaxedPriceBuilder, MethodTaxedPrice> builder) Total taxed prices based on the quantity of Line Item assigned to each Shipping Method. Only applicable for Carts with
Multiple
ShippingMode. Automatically set afterperMethodTaxRate
is set.- Parameters:
builder
- function to build the taxedPricePortions value- Returns:
- Builder
-
getLineItemId
Unique identifier for the Line Item.
- Returns:
- lineItemId
-
getLineItemKey
User-defined unique identifier of the LineItem.
- Returns:
- lineItemKey
-
getDiscountedPricePerQuantity
Array of DiscountedLineItemPriceForQuantity after the Discount recalculation.
- Returns:
- discountedPricePerQuantity
-
getTotalPrice
Total Price of the Line Item after the Discount recalculation.
- Returns:
- totalPrice
-
getTaxedPrice
TaxedItemPrice of the Line Item after the Discount recalculation.
- Returns:
- taxedPrice
-
getTaxedPricePortions
Total taxed prices based on the quantity of Line Item assigned to each Shipping Method. Only applicable for Carts with
Multiple
ShippingMode. Automatically set afterperMethodTaxRate
is set.- Returns:
- taxedPricePortions
-
build
builds OrderLineItemDiscountSetMessagePayload with checking for non-null required values- Specified by:
build
in interfaceBuilder<OrderLineItemDiscountSetMessagePayload>
- Returns:
- OrderLineItemDiscountSetMessagePayload
-
buildUnchecked
builds OrderLineItemDiscountSetMessagePayload without checking for non-null required values- Returns:
- OrderLineItemDiscountSetMessagePayload
-
of
factory method for an instance of OrderLineItemDiscountSetMessagePayloadBuilder- Returns:
- builder
-
of
public static OrderLineItemDiscountSetMessagePayloadBuilder of(OrderLineItemDiscountSetMessagePayload template) create builder for OrderLineItemDiscountSetMessagePayload instance- Parameters:
template
- instance with prefilled values for the builder- Returns:
- builder
-