Package com.stripe.param
Class ShippingRateCreateParams.Builder
- java.lang.Object
-
- com.stripe.param.ShippingRateCreateParams.Builder
-
- Enclosing class:
- ShippingRateCreateParams
public static class ShippingRateCreateParams.Builder extends java.lang.Object
-
-
Constructor Summary
Constructors Constructor Description Builder()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ShippingRateCreateParams.Builder
addAllExpand(java.util.List<java.lang.String> elements)
Add all elements to `expand` list.ShippingRateCreateParams.Builder
addExpand(java.lang.String element)
Add an element to `expand` list.ShippingRateCreateParams
build()
Finalize and obtain parameter instance from this builder.ShippingRateCreateParams.Builder
putAllExtraParam(java.util.Map<java.lang.String,java.lang.Object> map)
Add all map key/value pairs to `extraParams` map.ShippingRateCreateParams.Builder
putAllMetadata(java.util.Map<java.lang.String,java.lang.String> map)
Add all map key/value pairs to `metadata` map.ShippingRateCreateParams.Builder
putExtraParam(java.lang.String key, java.lang.Object value)
Add a key/value pair to `extraParams` map.ShippingRateCreateParams.Builder
putMetadata(java.lang.String key, java.lang.String value)
Add a key/value pair to `metadata` map.ShippingRateCreateParams.Builder
setDeliveryEstimate(ShippingRateCreateParams.DeliveryEstimate deliveryEstimate)
The estimated range for how long shipping will take, meant to be displayable to the customer.ShippingRateCreateParams.Builder
setDisplayName(java.lang.String displayName)
The name of the shipping rate, meant to be displayable to the customer.ShippingRateCreateParams.Builder
setFixedAmount(ShippingRateCreateParams.FixedAmount fixedAmount)
Describes a fixed amount to charge for shipping.ShippingRateCreateParams.Builder
setTaxBehavior(ShippingRateCreateParams.TaxBehavior taxBehavior)
Specifies whether the rate is considered inclusive of taxes or exclusive of taxes.ShippingRateCreateParams.Builder
setTaxCode(java.lang.String taxCode)
A tax code ID.ShippingRateCreateParams.Builder
setType(ShippingRateCreateParams.Type type)
The type of calculation to use on the shipping rate.
-
-
-
Method Detail
-
build
public ShippingRateCreateParams build()
Finalize and obtain parameter instance from this builder.
-
setDeliveryEstimate
public ShippingRateCreateParams.Builder setDeliveryEstimate(ShippingRateCreateParams.DeliveryEstimate deliveryEstimate)
The estimated range for how long shipping will take, meant to be displayable to the customer. This will appear on CheckoutSessions.
-
setDisplayName
public ShippingRateCreateParams.Builder setDisplayName(java.lang.String displayName)
The name of the shipping rate, meant to be displayable to the customer. This will appear on CheckoutSessions.
-
addExpand
public ShippingRateCreateParams.Builder addExpand(java.lang.String element)
Add an element to `expand` list. A list is initialized for the first `add/addAll` call, and subsequent calls adds additional elements to the original list. SeeShippingRateCreateParams.expand
for the field documentation.
-
addAllExpand
public ShippingRateCreateParams.Builder addAllExpand(java.util.List<java.lang.String> elements)
Add all elements to `expand` list. A list is initialized for the first `add/addAll` call, and subsequent calls adds additional elements to the original list. SeeShippingRateCreateParams.expand
for the field documentation.
-
putExtraParam
public ShippingRateCreateParams.Builder putExtraParam(java.lang.String key, java.lang.Object value)
Add a key/value pair to `extraParams` map. A map is initialized for the first `put/putAll` call, and subsequent calls add additional key/value pairs to the original map. SeeShippingRateCreateParams.extraParams
for the field documentation.
-
putAllExtraParam
public ShippingRateCreateParams.Builder putAllExtraParam(java.util.Map<java.lang.String,java.lang.Object> map)
Add all map key/value pairs to `extraParams` map. A map is initialized for the first `put/putAll` call, and subsequent calls add additional key/value pairs to the original map. SeeShippingRateCreateParams.extraParams
for the field documentation.
-
setFixedAmount
public ShippingRateCreateParams.Builder setFixedAmount(ShippingRateCreateParams.FixedAmount fixedAmount)
Describes a fixed amount to charge for shipping. Must be present if type isfixed_amount
.
-
putMetadata
public ShippingRateCreateParams.Builder putMetadata(java.lang.String key, java.lang.String value)
Add a key/value pair to `metadata` map. A map is initialized for the first `put/putAll` call, and subsequent calls add additional key/value pairs to the original map. SeeShippingRateCreateParams.metadata
for the field documentation.
-
putAllMetadata
public ShippingRateCreateParams.Builder putAllMetadata(java.util.Map<java.lang.String,java.lang.String> map)
Add all map key/value pairs to `metadata` map. A map is initialized for the first `put/putAll` call, and subsequent calls add additional key/value pairs to the original map. SeeShippingRateCreateParams.metadata
for the field documentation.
-
setTaxBehavior
public ShippingRateCreateParams.Builder setTaxBehavior(ShippingRateCreateParams.TaxBehavior taxBehavior)
Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One ofinclusive
,exclusive
, orunspecified
.
-
setTaxCode
public ShippingRateCreateParams.Builder setTaxCode(java.lang.String taxCode)
A tax code ID. The Shipping tax code istxcd_92010001
.
-
setType
public ShippingRateCreateParams.Builder setType(ShippingRateCreateParams.Type type)
The type of calculation to use on the shipping rate. Can only befixed_amount
for now.
-
-