Class CartDiscountChangeTargetActionBuilder
java.lang.Object
com.commercetools.api.models.cart_discount.CartDiscountChangeTargetActionBuilder
- All Implemented Interfaces:
Builder<CartDiscountChangeTargetAction>
public class CartDiscountChangeTargetActionBuilder
extends Object
implements Builder<CartDiscountChangeTargetAction>
CartDiscountChangeTargetActionBuilder
Example to create an instance using the builder pattern
Example to create an instance using the builder pattern
CartDiscountChangeTargetAction cartDiscountChangeTargetAction = CartDiscountChangeTargetAction.builder()
.target(targetBuilder -> targetBuilder)
.build()
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionbuild()
builds CartDiscountChangeTargetAction with checking for non-null required valuesbuilds CartDiscountChangeTargetAction without checking for non-null required valuesNew value to set.of()
factory method for an instance of CartDiscountChangeTargetActionBuilderof
(CartDiscountChangeTargetAction template) create builder for CartDiscountChangeTargetAction instancetarget
(CartDiscountTarget target) New value to set.target
(Function<CartDiscountTargetBuilder, Builder<? extends CartDiscountTarget>> builder) New value to set.
-
Constructor Details
-
CartDiscountChangeTargetActionBuilder
public CartDiscountChangeTargetActionBuilder()
-
-
Method Details
-
target
New value to set.
- Parameters:
target
- value to be set- Returns:
- Builder
-
target
public CartDiscountChangeTargetActionBuilder target(Function<CartDiscountTargetBuilder, Builder<? extends CartDiscountTarget>> builder) New value to set.
- Parameters:
builder
- function to build the target value- Returns:
- Builder
-
getTarget
New value to set.
- Returns:
- target
-
build
builds CartDiscountChangeTargetAction with checking for non-null required values- Specified by:
build
in interfaceBuilder<CartDiscountChangeTargetAction>
- Returns:
- CartDiscountChangeTargetAction
-
buildUnchecked
builds CartDiscountChangeTargetAction without checking for non-null required values- Returns:
- CartDiscountChangeTargetAction
-
of
factory method for an instance of CartDiscountChangeTargetActionBuilder- Returns:
- builder
-
of
create builder for CartDiscountChangeTargetAction instance- Parameters:
template
- instance with prefilled values for the builder- Returns:
- builder
-