Class PaymentInfoBuilder
java.lang.Object
com.commercetools.api.models.order.PaymentInfoBuilder
- All Implemented Interfaces:
Builder<PaymentInfo>
PaymentInfoBuilder
Example to create an instance using the builder pattern
Example to create an instance using the builder pattern
PaymentInfo paymentInfo = PaymentInfo.builder()
.plusPayments(paymentsBuilder -> paymentsBuilder)
.build()
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionReferences to the Payments associated with the Order.build()
builds PaymentInfo with checking for non-null required valuesbuilds PaymentInfo without checking for non-null required valuesReferences to the Payments associated with the Order.static PaymentInfoBuilder
of()
factory method for an instance of PaymentInfoBuilderstatic PaymentInfoBuilder
of
(PaymentInfo template) create builder for PaymentInfo instancepayments
(PaymentReference... payments) References to the Payments associated with the Order.payments
(List<PaymentReference> payments) References to the Payments associated with the Order.plusPayments
(PaymentReference... payments) References to the Payments associated with the Order.References to the Payments associated with the Order.References to the Payments associated with the Order.References to the Payments associated with the Order.
-
Constructor Details
-
PaymentInfoBuilder
public PaymentInfoBuilder()
-
-
Method Details
-
payments
References to the Payments associated with the Order.
- Parameters:
payments
- value to be set- Returns:
- Builder
-
payments
References to the Payments associated with the Order.
- Parameters:
payments
- value to be set- Returns:
- Builder
-
plusPayments
References to the Payments associated with the Order.
- Parameters:
payments
- value to be set- Returns:
- Builder
-
plusPayments
public PaymentInfoBuilder plusPayments(Function<PaymentReferenceBuilder, PaymentReferenceBuilder> builder) References to the Payments associated with the Order.
- Parameters:
builder
- function to build the payments value- Returns:
- Builder
-
withPayments
public PaymentInfoBuilder withPayments(Function<PaymentReferenceBuilder, PaymentReferenceBuilder> builder) References to the Payments associated with the Order.
- Parameters:
builder
- function to build the payments value- Returns:
- Builder
-
addPayments
References to the Payments associated with the Order.
- Parameters:
builder
- function to build the payments value- Returns:
- Builder
-
setPayments
References to the Payments associated with the Order.
- Parameters:
builder
- function to build the payments value- Returns:
- Builder
-
getPayments
References to the Payments associated with the Order.
- Returns:
- payments
-
build
builds PaymentInfo with checking for non-null required values- Specified by:
build
in interfaceBuilder<PaymentInfo>
- Returns:
- PaymentInfo
-
buildUnchecked
builds PaymentInfo without checking for non-null required values- Returns:
- PaymentInfo
-
of
factory method for an instance of PaymentInfoBuilder- Returns:
- builder
-
of
create builder for PaymentInfo instance- Parameters:
template
- instance with prefilled values for the builder- Returns:
- builder
-