Class ShoppingListChangeTextLineItemQuantityActionBuilder
java.lang.Object
com.commercetools.api.models.shopping_list.ShoppingListChangeTextLineItemQuantityActionBuilder
- All Implemented Interfaces:
Builder<ShoppingListChangeTextLineItemQuantityAction>
public class ShoppingListChangeTextLineItemQuantityActionBuilder
extends Object
implements Builder<ShoppingListChangeTextLineItemQuantityAction>
ShoppingListChangeTextLineItemQuantityActionBuilder
Example to create an instance using the builder pattern
Example to create an instance using the builder pattern
ShoppingListChangeTextLineItemQuantityAction shoppingListChangeTextLineItemQuantityAction = ShoppingListChangeTextLineItemQuantityAction.builder()
.quantity(0.3)
.build()
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionbuild()
builds ShoppingListChangeTextLineItemQuantityAction with checking for non-null required valuesbuilds ShoppingListChangeTextLineItemQuantityAction without checking for non-null required valuesNew value to set.Theid
of the TextLineItem to update.Thekey
of the TextLineItem to update.of()
factory method for an instance of ShoppingListChangeTextLineItemQuantityActionBuildercreate builder for ShoppingListChangeTextLineItemQuantityAction instanceNew value to set.textLineItemId
(String textLineItemId) Theid
of the TextLineItem to update.textLineItemKey
(String textLineItemKey) Thekey
of the TextLineItem to update.
-
Constructor Details
-
ShoppingListChangeTextLineItemQuantityActionBuilder
public ShoppingListChangeTextLineItemQuantityActionBuilder()
-
-
Method Details
-
textLineItemId
public ShoppingListChangeTextLineItemQuantityActionBuilder textLineItemId(@Nullable String textLineItemId) The
id
of the TextLineItem to update. EitherlineItemId
orlineItemKey
is required.- Parameters:
textLineItemId
- value to be set- Returns:
- Builder
-
textLineItemKey
public ShoppingListChangeTextLineItemQuantityActionBuilder textLineItemKey(@Nullable String textLineItemKey) The
key
of the TextLineItem to update. EitherlineItemId
orlineItemKey
is required.- Parameters:
textLineItemKey
- value to be set- Returns:
- Builder
-
quantity
New value to set. If
0
, the TextLineItem is removed from the ShoppingList.- Parameters:
quantity
- value to be set- Returns:
- Builder
-
getTextLineItemId
The
id
of the TextLineItem to update. EitherlineItemId
orlineItemKey
is required.- Returns:
- textLineItemId
-
getTextLineItemKey
The
key
of the TextLineItem to update. EitherlineItemId
orlineItemKey
is required.- Returns:
- textLineItemKey
-
getQuantity
New value to set. If
0
, the TextLineItem is removed from the ShoppingList.- Returns:
- quantity
-
build
builds ShoppingListChangeTextLineItemQuantityAction with checking for non-null required values- Specified by:
build
in interfaceBuilder<ShoppingListChangeTextLineItemQuantityAction>
- Returns:
- ShoppingListChangeTextLineItemQuantityAction
-
buildUnchecked
builds ShoppingListChangeTextLineItemQuantityAction without checking for non-null required values- Returns:
- ShoppingListChangeTextLineItemQuantityAction
-
of
factory method for an instance of ShoppingListChangeTextLineItemQuantityActionBuilder- Returns:
- builder
-
of
public static ShoppingListChangeTextLineItemQuantityActionBuilder of(ShoppingListChangeTextLineItemQuantityAction template) create builder for ShoppingListChangeTextLineItemQuantityAction instance- Parameters:
template
- instance with prefilled values for the builder- Returns:
- builder
-