Class CartRemovePaymentActionBuilder
java.lang.Object
com.commercetools.api.models.cart.CartRemovePaymentActionBuilder
- All Implemented Interfaces:
Builder<CartRemovePaymentAction>
public class CartRemovePaymentActionBuilder
extends Object
implements Builder<CartRemovePaymentAction>
CartRemovePaymentActionBuilder
Example to create an instance using the builder pattern
Example to create an instance using the builder pattern
CartRemovePaymentAction cartRemovePaymentAction = CartRemovePaymentAction.builder()
.payment(paymentBuilder -> paymentBuilder)
.build()
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionbuild()
builds CartRemovePaymentAction with checking for non-null required valuesbuilds CartRemovePaymentAction without checking for non-null required valuesPayment to remove from the Cart.of()
factory method for an instance of CartRemovePaymentActionBuilderof
(CartRemovePaymentAction template) create builder for CartRemovePaymentAction instancepayment
(PaymentResourceIdentifier payment) Payment to remove from the Cart.Payment to remove from the Cart.Payment to remove from the Cart.
-
Constructor Details
-
CartRemovePaymentActionBuilder
public CartRemovePaymentActionBuilder()
-
-
Method Details
-
payment
public CartRemovePaymentActionBuilder payment(Function<PaymentResourceIdentifierBuilder, PaymentResourceIdentifierBuilder> builder) Payment to remove from the Cart.
- Parameters:
builder
- function to build the payment value- Returns:
- Builder
-
withPayment
public CartRemovePaymentActionBuilder withPayment(Function<PaymentResourceIdentifierBuilder, PaymentResourceIdentifier> builder) Payment to remove from the Cart.
- Parameters:
builder
- function to build the payment value- Returns:
- Builder
-
payment
Payment to remove from the Cart.
- Parameters:
payment
- value to be set- Returns:
- Builder
-
getPayment
Payment to remove from the Cart.
- Returns:
- payment
-
build
builds CartRemovePaymentAction with checking for non-null required values- Specified by:
build
in interfaceBuilder<CartRemovePaymentAction>
- Returns:
- CartRemovePaymentAction
-
buildUnchecked
builds CartRemovePaymentAction without checking for non-null required values- Returns:
- CartRemovePaymentAction
-
of
factory method for an instance of CartRemovePaymentActionBuilder- Returns:
- builder
-
of
create builder for CartRemovePaymentAction instance- Parameters:
template
- instance with prefilled values for the builder- Returns:
- builder
-