Class SetCustomLineItemDiscountedPricePerQuantityChangeBuilder
java.lang.Object
com.commercetools.history.models.change.SetCustomLineItemDiscountedPricePerQuantityChangeBuilder
- All Implemented Interfaces:
Builder<SetCustomLineItemDiscountedPricePerQuantityChange>
public class SetCustomLineItemDiscountedPricePerQuantityChangeBuilder
extends Object
implements Builder<SetCustomLineItemDiscountedPricePerQuantityChange>
SetCustomLineItemDiscountedPricePerQuantityChangeBuilder
Example to create an instance using the builder pattern
Example to create an instance using the builder pattern
SetCustomLineItemDiscountedPricePerQuantityChange setCustomLineItemDiscountedPricePerQuantityChange = SetCustomLineItemDiscountedPricePerQuantityChange.builder()
.change("{change}")
.customLineItem(customLineItemBuilder -> customLineItemBuilder)
.customLineItemId("{customLineItemId}")
.previousValue(previousValueBuilder -> previousValueBuilder)
.nextValue(nextValueBuilder -> nextValueBuilder)
.build()
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()builds SetCustomLineItemDiscountedPricePerQuantityChange with checking for non-null required valuesbuilds SetCustomLineItemDiscountedPricePerQuantityChange without checking for non-null required valuesset the value to the changecustomLineItem(LocalizedString customLineItem) Name of the updated CustomLineItem.Name of the updated CustomLineItem.customLineItemId(String customLineItemId) idof the updated CustomLineItem.value of change}Name of the updated CustomLineItem.idof the updated CustomLineItem.Value after the change.Value before the change.nextValue(DiscountedLineItemPriceForQuantity nextValue) Value after the change.nextValue(Function<DiscountedLineItemPriceForQuantityBuilder, DiscountedLineItemPriceForQuantityBuilder> builder) Value after the change.of()factory method for an instance of SetCustomLineItemDiscountedPricePerQuantityChangeBuildercreate builder for SetCustomLineItemDiscountedPricePerQuantityChange instancepreviousValue(DiscountedLineItemPriceForQuantity previousValue) Value before the change.previousValue(Function<DiscountedLineItemPriceForQuantityBuilder, DiscountedLineItemPriceForQuantityBuilder> builder) Value before the change.Name of the updated CustomLineItem.withNextValue(Function<DiscountedLineItemPriceForQuantityBuilder, DiscountedLineItemPriceForQuantity> builder) Value after the change.withPreviousValue(Function<DiscountedLineItemPriceForQuantityBuilder, DiscountedLineItemPriceForQuantity> builder) Value before the change.
-
Constructor Details
-
SetCustomLineItemDiscountedPricePerQuantityChangeBuilder
public SetCustomLineItemDiscountedPricePerQuantityChangeBuilder()
-
-
Method Details
-
change
set the value to the change- Parameters:
change- value to be set- Returns:
- Builder
-
customLineItem
public SetCustomLineItemDiscountedPricePerQuantityChangeBuilder customLineItem(Function<LocalizedStringBuilder, LocalizedStringBuilder> builder) Name of the updated CustomLineItem.
- Parameters:
builder- function to build the customLineItem value- Returns:
- Builder
-
withCustomLineItem
public SetCustomLineItemDiscountedPricePerQuantityChangeBuilder withCustomLineItem(Function<LocalizedStringBuilder, LocalizedString> builder) Name of the updated CustomLineItem.
- Parameters:
builder- function to build the customLineItem value- Returns:
- Builder
-
customLineItem
public SetCustomLineItemDiscountedPricePerQuantityChangeBuilder customLineItem(LocalizedString customLineItem) Name of the updated CustomLineItem.
- Parameters:
customLineItem- value to be set- Returns:
- Builder
-
customLineItemId
public SetCustomLineItemDiscountedPricePerQuantityChangeBuilder customLineItemId(String customLineItemId) idof the updated CustomLineItem.- Parameters:
customLineItemId- value to be set- Returns:
- Builder
-
previousValue
public SetCustomLineItemDiscountedPricePerQuantityChangeBuilder previousValue(Function<DiscountedLineItemPriceForQuantityBuilder, DiscountedLineItemPriceForQuantityBuilder> builder) Value before the change.
- Parameters:
builder- function to build the previousValue value- Returns:
- Builder
-
withPreviousValue
public SetCustomLineItemDiscountedPricePerQuantityChangeBuilder withPreviousValue(Function<DiscountedLineItemPriceForQuantityBuilder, DiscountedLineItemPriceForQuantity> builder) Value before the change.
- Parameters:
builder- function to build the previousValue value- Returns:
- Builder
-
previousValue
public SetCustomLineItemDiscountedPricePerQuantityChangeBuilder previousValue(DiscountedLineItemPriceForQuantity previousValue) Value before the change.
- Parameters:
previousValue- value to be set- Returns:
- Builder
-
nextValue
public SetCustomLineItemDiscountedPricePerQuantityChangeBuilder nextValue(Function<DiscountedLineItemPriceForQuantityBuilder, DiscountedLineItemPriceForQuantityBuilder> builder) Value after the change.
- Parameters:
builder- function to build the nextValue value- Returns:
- Builder
-
withNextValue
public SetCustomLineItemDiscountedPricePerQuantityChangeBuilder withNextValue(Function<DiscountedLineItemPriceForQuantityBuilder, DiscountedLineItemPriceForQuantity> builder) Value after the change.
- Parameters:
builder- function to build the nextValue value- Returns:
- Builder
-
nextValue
public SetCustomLineItemDiscountedPricePerQuantityChangeBuilder nextValue(DiscountedLineItemPriceForQuantity nextValue) Value after the change.
- Parameters:
nextValue- value to be set- Returns:
- Builder
-
getChange
value of change}- Returns:
- change
-
getCustomLineItem
Name of the updated CustomLineItem.
- Returns:
- customLineItem
-
getCustomLineItemId
idof the updated CustomLineItem.- Returns:
- customLineItemId
-
getPreviousValue
Value before the change.
- Returns:
- previousValue
-
getNextValue
Value after the change.
- Returns:
- nextValue
-
build
builds SetCustomLineItemDiscountedPricePerQuantityChange with checking for non-null required values- Specified by:
buildin interfaceBuilder<SetCustomLineItemDiscountedPricePerQuantityChange>- Returns:
- SetCustomLineItemDiscountedPricePerQuantityChange
-
buildUnchecked
builds SetCustomLineItemDiscountedPricePerQuantityChange without checking for non-null required values- Returns:
- SetCustomLineItemDiscountedPricePerQuantityChange
-
of
factory method for an instance of SetCustomLineItemDiscountedPricePerQuantityChangeBuilder- Returns:
- builder
-
of
public static SetCustomLineItemDiscountedPricePerQuantityChangeBuilder of(SetCustomLineItemDiscountedPricePerQuantityChange template) create builder for SetCustomLineItemDiscountedPricePerQuantityChange instance- Parameters:
template- instance with prefilled values for the builder- Returns:
- builder
-