Class SetParcelItemsChangeBuilder
java.lang.Object
com.commercetools.history.models.change.SetParcelItemsChangeBuilder
- All Implemented Interfaces:
Builder<SetParcelItemsChange>
SetParcelItemsChangeBuilder
Example to create an instance using the builder pattern
Example to create an instance using the builder pattern
SetParcelItemsChange setParcelItemsChange = SetParcelItemsChange.builder()
.change("{change}")
.plusPreviousValue(previousValueBuilder -> previousValueBuilder)
.plusNextValue(nextValueBuilder -> nextValueBuilder)
.parcel(parcelBuilder -> parcelBuilder)
.build()
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionaddNextValue
(Function<DeliveryItemBuilder, DeliveryItem> builder) Value after the change.Value before the change.build()
builds SetParcelItemsChange with checking for non-null required valuesbuilds SetParcelItemsChange without checking for non-null required valuesset the value to the changevalue of change}Value after the change.Information about the updated Parcel.Value before the change.nextValue
(DeliveryItem... nextValue) Value after the change.nextValue
(List<DeliveryItem> nextValue) Value after the change.static SetParcelItemsChangeBuilder
of()
factory method for an instance of SetParcelItemsChangeBuilderstatic SetParcelItemsChangeBuilder
of
(SetParcelItemsChange template) create builder for SetParcelItemsChange instanceparcel
(ParcelChangeValue parcel) Information about the updated Parcel.Information about the updated Parcel.plusNextValue
(DeliveryItem... nextValue) Value after the change.Value after the change.plusPreviousValue
(DeliveryItem... previousValue) Value before the change.Value before the change.previousValue
(DeliveryItem... previousValue) Value before the change.previousValue
(List<DeliveryItem> previousValue) Value before the change.setNextValue
(Function<DeliveryItemBuilder, DeliveryItem> builder) Value after the change.Value before the change.Value after the change.Information about the updated Parcel.Value before the change.
-
Constructor Details
-
SetParcelItemsChangeBuilder
public SetParcelItemsChangeBuilder()
-
-
Method Details
-
change
set the value to the change- Parameters:
change
- value to be set- Returns:
- Builder
-
previousValue
Value before the change.
- Parameters:
previousValue
- value to be set- Returns:
- Builder
-
previousValue
Value before the change.
- Parameters:
previousValue
- value to be set- Returns:
- Builder
-
plusPreviousValue
Value before the change.
- Parameters:
previousValue
- value to be set- Returns:
- Builder
-
plusPreviousValue
public SetParcelItemsChangeBuilder plusPreviousValue(Function<DeliveryItemBuilder, DeliveryItemBuilder> builder) Value before the change.
- Parameters:
builder
- function to build the previousValue value- Returns:
- Builder
-
withPreviousValue
public SetParcelItemsChangeBuilder withPreviousValue(Function<DeliveryItemBuilder, DeliveryItemBuilder> builder) Value before the change.
- Parameters:
builder
- function to build the previousValue value- Returns:
- Builder
-
addPreviousValue
public SetParcelItemsChangeBuilder addPreviousValue(Function<DeliveryItemBuilder, DeliveryItem> builder) Value before the change.
- Parameters:
builder
- function to build the previousValue value- Returns:
- Builder
-
setPreviousValue
public SetParcelItemsChangeBuilder setPreviousValue(Function<DeliveryItemBuilder, DeliveryItem> builder) Value before the change.
- Parameters:
builder
- function to build the previousValue value- Returns:
- Builder
-
nextValue
Value after the change.
- Parameters:
nextValue
- value to be set- Returns:
- Builder
-
nextValue
Value after the change.
- Parameters:
nextValue
- value to be set- Returns:
- Builder
-
plusNextValue
Value after the change.
- Parameters:
nextValue
- value to be set- Returns:
- Builder
-
plusNextValue
public SetParcelItemsChangeBuilder plusNextValue(Function<DeliveryItemBuilder, DeliveryItemBuilder> builder) Value after the change.
- Parameters:
builder
- function to build the nextValue value- Returns:
- Builder
-
withNextValue
public SetParcelItemsChangeBuilder withNextValue(Function<DeliveryItemBuilder, DeliveryItemBuilder> builder) Value after the change.
- Parameters:
builder
- function to build the nextValue value- Returns:
- Builder
-
addNextValue
Value after the change.
- Parameters:
builder
- function to build the nextValue value- Returns:
- Builder
-
setNextValue
Value after the change.
- Parameters:
builder
- function to build the nextValue value- Returns:
- Builder
-
parcel
public SetParcelItemsChangeBuilder parcel(Function<ParcelChangeValueBuilder, ParcelChangeValueBuilder> builder) Information about the updated Parcel.
- Parameters:
builder
- function to build the parcel value- Returns:
- Builder
-
withParcel
public SetParcelItemsChangeBuilder withParcel(Function<ParcelChangeValueBuilder, ParcelChangeValue> builder) Information about the updated Parcel.
- Parameters:
builder
- function to build the parcel value- Returns:
- Builder
-
parcel
Information about the updated Parcel.
- Parameters:
parcel
- value to be set- Returns:
- Builder
-
getChange
value of change}- Returns:
- change
-
getPreviousValue
Value before the change.
- Returns:
- previousValue
-
getNextValue
Value after the change.
- Returns:
- nextValue
-
getParcel
Information about the updated Parcel.
- Returns:
- parcel
-
build
builds SetParcelItemsChange with checking for non-null required values- Specified by:
build
in interfaceBuilder<SetParcelItemsChange>
- Returns:
- SetParcelItemsChange
-
buildUnchecked
builds SetParcelItemsChange without checking for non-null required values- Returns:
- SetParcelItemsChange
-
of
factory method for an instance of SetParcelItemsChangeBuilder- Returns:
- builder
-
of
create builder for SetParcelItemsChange instance- Parameters:
template
- instance with prefilled values for the builder- Returns:
- builder
-