public final class CartDraftBuilder extends Base
Modifier and Type | Method and Description |
---|---|
T |
anonymousId(String anonymousId)
Sets the
anonymousId property of this builder. |
T |
billingAddress(Address billingAddress)
Sets the
billingAddress property of this builder. |
CartDraftDsl |
build()
Creates a new instance of
CartDraftDsl with the values of this builder. |
T |
country(com.neovisionaries.i18n.CountryCode country)
Sets the
country property of this builder. |
T |
currency(javax.money.CurrencyUnit currency)
Sets the
currency property of this builder. |
T |
custom(CustomFieldsDraft custom)
Sets the
custom property of this builder. |
T |
customerEmail(String customerEmail)
Sets the
customerEmail property of this builder. |
T |
customerGroup(ResourceIdentifier<CustomerGroup> customerGroup)
Sets the
customerGroup property of this builder. |
T |
customerId(String customerId)
Sets the
customerId property of this builder. |
T |
customLineItems(List<CustomLineItemDraft> customLineItems)
Sets the
customLineItems property of this builder. |
T |
deleteDaysAfterLastModification(Integer deleteDaysAfterLastModification)
Sets the
deleteDaysAfterLastModification property of this builder. |
T |
discountCodes(List<String> discountCodes)
Sets the
discountCodes property of this builder. |
T |
externalTaxRateForShippingMethod(ExternalTaxRateDraft externalTaxRateForShippingMethod)
Sets the
externalTaxRateForShippingMethod property of this builder. |
String |
getAnonymousId() |
Address |
getBillingAddress() |
com.neovisionaries.i18n.CountryCode |
getCountry() |
javax.money.CurrencyUnit |
getCurrency() |
CustomFieldsDraft |
getCustom() |
String |
getCustomerEmail() |
ResourceIdentifier<CustomerGroup> |
getCustomerGroup() |
String |
getCustomerId() |
List<CustomLineItemDraft> |
getCustomLineItems() |
Integer |
getDeleteDaysAfterLastModification() |
List<String> |
getDiscountCodes() |
ExternalTaxRateDraft |
getExternalTaxRateForShippingMethod() |
InventoryMode |
getInventoryMode() |
List<Address> |
getItemShippingAddresses() |
List<LineItemDraft> |
getLineItems() |
Locale |
getLocale() |
CartOrigin |
getOrigin() |
Address |
getShippingAddress() |
ResourceIdentifier<ShippingMethod> |
getShippingMethod() |
ShippingRateInputDraft |
getShippingRateInput() |
ResourceIdentifier<Store> |
getStore() |
TaxCalculationMode |
getTaxCalculationMode() |
TaxMode |
getTaxMode() |
RoundingMode |
getTaxRoundingMode() |
T |
inventoryMode(InventoryMode inventoryMode)
Sets the
inventoryMode property of this builder. |
T |
itemShippingAddresses(List<Address> itemShippingAddresses)
Sets the
itemShippingAddresses property of this builder. |
T |
lineItems(List<LineItemDraft> lineItems)
Sets the
lineItems property of this builder. |
T |
locale(Locale locale)
Sets the
locale property of this builder. |
static CartDraftBuilder |
of(CartDraft template)
Creates a new object initialized with the fields of the template parameter.
|
static CartDraftBuilder |
of(javax.money.CurrencyUnit currency)
Creates a new object initialized with the given values.
|
T |
origin(CartOrigin origin)
Sets the
origin property of this builder. |
T |
plusCustomLineItems(CustomLineItemDraft customLineItems)
Adds
customLineItems parameter to the customLineItems list property of this builder. |
T |
plusCustomLineItems(List<CustomLineItemDraft> customLineItems)
Concatenate
customLineItems parameter to the customLineItems list property of this builder. |
T |
plusDiscountCodes(List<String> discountCodes)
Concatenate
discountCodes parameter to the discountCodes list property of this builder. |
T |
plusDiscountCodes(String discountCodes)
Adds
discountCodes parameter to the discountCodes list property of this builder. |
T |
plusItemShippingAddresses(Address itemShippingAddresses)
Adds
itemShippingAddresses parameter to the itemShippingAddresses list property of this builder. |
T |
plusItemShippingAddresses(List<Address> itemShippingAddresses)
Concatenate
itemShippingAddresses parameter to the itemShippingAddresses list property of this builder. |
T |
plusLineItems(LineItemDraft lineItems)
Adds
lineItems parameter to the lineItems list property of this builder. |
T |
plusLineItems(List<LineItemDraft> lineItems)
Concatenate
lineItems parameter to the lineItems list property of this builder. |
T |
shippingAddress(Address shippingAddress)
Sets the
shippingAddress property of this builder. |
CartDraftBuilder |
shippingMethod(Referenceable<ShippingMethod> shippingMethod) |
T |
shippingMethod(ResourceIdentifier<ShippingMethod> shippingMethod)
Sets the
shippingMethod property of this builder. |
T |
shippingRateInput(ShippingRateInputDraft shippingRateInput)
Sets the
shippingRateInput property of this builder. |
T |
store(ResourceIdentifier<Store> store)
Sets the
store property of this builder. |
T |
taxCalculationMode(TaxCalculationMode taxCalculationMode)
Sets the
taxCalculationMode property of this builder. |
T |
taxMode(TaxMode taxMode)
Sets the
taxMode property of this builder. |
T |
taxRoundingMode(RoundingMode taxRoundingMode)
Sets the
taxRoundingMode property of this builder. |
public CartDraftBuilder shippingMethod(@Nullable Referenceable<ShippingMethod> shippingMethod)
public T anonymousId(@Nullable String anonymousId)
anonymousId
property of this builder.anonymousId
- the value for CartDraft.getAnonymousId()
public T billingAddress(@Nullable Address billingAddress)
billingAddress
property of this builder.billingAddress
- the value for CartDraft.getBillingAddress()
public T country(@Nullable com.neovisionaries.i18n.CountryCode country)
country
property of this builder.country
- the value for CartDraft.getCountry()
public T currency(javax.money.CurrencyUnit currency)
currency
property of this builder.currency
- the value for CartDraft.getCurrency()
public T custom(@Nullable CustomFieldsDraft custom)
custom
property of this builder.custom
- the value for CartDraft.getCustom()
public T customLineItems(@Nullable List<CustomLineItemDraft> customLineItems)
customLineItems
property of this builder.customLineItems
- the value for CartDraft.getCustomLineItems()
public T customerEmail(@Nullable String customerEmail)
customerEmail
property of this builder.customerEmail
- the value for CartDraft.getCustomerEmail()
public T customerGroup(@Nullable ResourceIdentifier<CustomerGroup> customerGroup)
customerGroup
property of this builder.customerGroup
- the value for CartDraft.getCustomerGroup()
public T customerId(@Nullable String customerId)
customerId
property of this builder.customerId
- the value for CartDraft.getCustomerId()
public T deleteDaysAfterLastModification(@Nullable Integer deleteDaysAfterLastModification)
deleteDaysAfterLastModification
property of this builder.deleteDaysAfterLastModification
- the value for CartDraft.getDeleteDaysAfterLastModification()
public T discountCodes(@Nullable List<String> discountCodes)
discountCodes
property of this builder.discountCodes
- the value for CartDraft.getDiscountCodes()
public T externalTaxRateForShippingMethod(@Nullable ExternalTaxRateDraft externalTaxRateForShippingMethod)
externalTaxRateForShippingMethod
property of this builder.externalTaxRateForShippingMethod
- the value for CartDraft.getExternalTaxRateForShippingMethod()
public T inventoryMode(@Nullable InventoryMode inventoryMode)
inventoryMode
property of this builder.inventoryMode
- the value for CartDraft.getInventoryMode()
public T itemShippingAddresses(@Nullable List<Address> itemShippingAddresses)
itemShippingAddresses
property of this builder.itemShippingAddresses
- the value for CartDraft.getItemShippingAddresses()
public T lineItems(@Nullable List<LineItemDraft> lineItems)
lineItems
property of this builder.lineItems
- the value for CartDraft.getLineItems()
public T locale(@Nullable Locale locale)
locale
property of this builder.locale
- the value for CartDraft.getLocale()
public T origin(@Nullable CartOrigin origin)
origin
property of this builder.origin
- the value for CartDraft.getOrigin()
public T shippingAddress(@Nullable Address shippingAddress)
shippingAddress
property of this builder.shippingAddress
- the value for CartDraft.getShippingAddress()
public T shippingMethod(@Nullable ResourceIdentifier<ShippingMethod> shippingMethod)
shippingMethod
property of this builder.shippingMethod
- the value for CartDraft.getShippingMethod()
public T shippingRateInput(@Nullable ShippingRateInputDraft shippingRateInput)
shippingRateInput
property of this builder.shippingRateInput
- the value for CartDraft.getShippingRateInput()
public T store(@Nullable ResourceIdentifier<Store> store)
store
property of this builder.store
- the value for CartDraft.getStore()
public T taxCalculationMode(@Nullable TaxCalculationMode taxCalculationMode)
taxCalculationMode
property of this builder.taxCalculationMode
- the value for CartDraft.getTaxCalculationMode()
public T taxMode(@Nullable TaxMode taxMode)
taxMode
property of this builder.taxMode
- the value for CartDraft.getTaxMode()
public T taxRoundingMode(@Nullable RoundingMode taxRoundingMode)
taxRoundingMode
property of this builder.taxRoundingMode
- the value for CartDraft.getTaxRoundingMode()
@Nullable public com.neovisionaries.i18n.CountryCode getCountry()
public javax.money.CurrencyUnit getCurrency()
@Nullable public CustomFieldsDraft getCustom()
@Nullable public List<CustomLineItemDraft> getCustomLineItems()
@Nullable public ResourceIdentifier<CustomerGroup> getCustomerGroup()
@Nullable public ExternalTaxRateDraft getExternalTaxRateForShippingMethod()
@Nullable public InventoryMode getInventoryMode()
@Nullable public List<LineItemDraft> getLineItems()
@Nullable public CartOrigin getOrigin()
@Nullable public ResourceIdentifier<ShippingMethod> getShippingMethod()
@Nullable public ShippingRateInputDraft getShippingRateInput()
@Nullable public ResourceIdentifier<Store> getStore()
@Nullable public TaxCalculationMode getTaxCalculationMode()
@Nullable public RoundingMode getTaxRoundingMode()
public T plusCustomLineItems(List<CustomLineItemDraft> customLineItems)
customLineItems
parameter to the customLineItems
list property of this builder.customLineItems
- the value for CartDraft.getCustomLineItems()
public T plusDiscountCodes(List<String> discountCodes)
discountCodes
parameter to the discountCodes
list property of this builder.discountCodes
- the value for CartDraft.getDiscountCodes()
public T plusItemShippingAddresses(List<Address> itemShippingAddresses)
itemShippingAddresses
parameter to the itemShippingAddresses
list property of this builder.itemShippingAddresses
- the value for CartDraft.getItemShippingAddresses()
public T plusLineItems(List<LineItemDraft> lineItems)
lineItems
parameter to the lineItems
list property of this builder.lineItems
- the value for CartDraft.getLineItems()
public T plusCustomLineItems(CustomLineItemDraft customLineItems)
customLineItems
parameter to the customLineItems
list property of this builder.customLineItems
- the value of the element to add to CartDraft.getCustomLineItems()
public T plusDiscountCodes(String discountCodes)
discountCodes
parameter to the discountCodes
list property of this builder.discountCodes
- the value of the element to add to CartDraft.getDiscountCodes()
public T plusItemShippingAddresses(Address itemShippingAddresses)
itemShippingAddresses
parameter to the itemShippingAddresses
list property of this builder.itemShippingAddresses
- the value of the element to add to CartDraft.getItemShippingAddresses()
public T plusLineItems(LineItemDraft lineItems)
lineItems
parameter to the lineItems
list property of this builder.lineItems
- the value of the element to add to CartDraft.getLineItems()
public CartDraftDsl build()
CartDraftDsl
with the values of this builder.build
in interface Builder<CartDraftDsl>
public static CartDraftBuilder of(javax.money.CurrencyUnit currency)
currency
- initial value for the CartDraft.getCurrency()
propertypublic static CartDraftBuilder of(CartDraft template)
template
- the template