Class SetOrderLineItemCustomFieldChangeBuilder
java.lang.Object
com.commercetools.history.models.change.SetOrderLineItemCustomFieldChangeBuilder
- All Implemented Interfaces:
Builder<SetOrderLineItemCustomFieldChange>
public class SetOrderLineItemCustomFieldChangeBuilder
extends Object
implements Builder<SetOrderLineItemCustomFieldChange>
SetOrderLineItemCustomFieldChangeBuilder
Example to create an instance using the builder pattern
Example to create an instance using the builder pattern
SetOrderLineItemCustomFieldChange setOrderLineItemCustomFieldChange = SetOrderLineItemCustomFieldChange.builder()
.change("{change}")
.customTypeId("{customTypeId}")
.name("{name}")
.lineItem(lineItemBuilder -> lineItemBuilder)
.variant("{variant}")
.build()
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionbuild()
builds SetOrderLineItemCustomFieldChange with checking for non-null required valuesbuilds SetOrderLineItemCustomFieldChange without checking for non-null required valuesset the value to the changecustomTypeId
(String customTypeId) id
of the referenced Type.value of change}id
of the referenced Type.Name of the Product the Line Item is based on.getName()
Name of the Custom Field.Value after the change.Value before the change.sku
orkey
of the ProductVariant.lineItem
(LocalizedString lineItem) Name of the Product the Line Item is based on.Name of the Product the Line Item is based on.Name of the Custom Field.Value after the change.of()
factory method for an instance of SetOrderLineItemCustomFieldChangeBuilderof
(SetOrderLineItemCustomFieldChange template) create builder for SetOrderLineItemCustomFieldChange instancepreviousValue
(Object previousValue) Value before the change.sku
orkey
of the ProductVariant.Name of the Product the Line Item is based on.
-
Constructor Details
-
SetOrderLineItemCustomFieldChangeBuilder
public SetOrderLineItemCustomFieldChangeBuilder()
-
-
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
-
nextValue
Value after the change.
- Parameters:
nextValue
- value to be set- Returns:
- Builder
-
customTypeId
id
of the referenced Type.- Parameters:
customTypeId
- value to be set- Returns:
- Builder
-
name
Name of the Custom Field.
- Parameters:
name
- value to be set- Returns:
- Builder
-
lineItem
public SetOrderLineItemCustomFieldChangeBuilder lineItem(Function<LocalizedStringBuilder, LocalizedStringBuilder> builder) Name of the Product the Line Item is based on.
- Parameters:
builder
- function to build the lineItem value- Returns:
- Builder
-
withLineItem
public SetOrderLineItemCustomFieldChangeBuilder withLineItem(Function<LocalizedStringBuilder, LocalizedString> builder) Name of the Product the Line Item is based on.
- Parameters:
builder
- function to build the lineItem value- Returns:
- Builder
-
lineItem
Name of the Product the Line Item is based on.
- Parameters:
lineItem
- value to be set- Returns:
- Builder
-
variant
sku
orkey
of the ProductVariant.- Parameters:
variant
- 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
-
getCustomTypeId
id
of the referenced Type.- Returns:
- customTypeId
-
getName
Name of the Custom Field.
- Returns:
- name
-
getLineItem
Name of the Product the Line Item is based on.
- Returns:
- lineItem
-
getVariant
sku
orkey
of the ProductVariant.- Returns:
- variant
-
build
builds SetOrderLineItemCustomFieldChange with checking for non-null required values- Specified by:
build
in interfaceBuilder<SetOrderLineItemCustomFieldChange>
- Returns:
- SetOrderLineItemCustomFieldChange
-
buildUnchecked
builds SetOrderLineItemCustomFieldChange without checking for non-null required values- Returns:
- SetOrderLineItemCustomFieldChange
-
of
factory method for an instance of SetOrderLineItemCustomFieldChangeBuilder- Returns:
- builder
-
of
public static SetOrderLineItemCustomFieldChangeBuilder of(SetOrderLineItemCustomFieldChange template) create builder for SetOrderLineItemCustomFieldChange instance- Parameters:
template
- instance with prefilled values for the builder- Returns:
- builder
-