Interface AbsoluteAllocation
- All Superinterfaces:
Allocation
Allocates a fixed amount of the Order total to a Payment Method.
Example to create an instance using the builder pattern
AbsoluteAllocation absoluteAllocation = AbsoluteAllocation.builder()
.amount(amountBuilder -> amountBuilder)
.build()
-
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionstatic AbsoluteAllocationBuilderbuilder()builder factory method for AbsoluteAllocationstatic AbsoluteAllocationBuilderbuilder(AbsoluteAllocation template) create builder for AbsoluteAllocation instancecopyDeep()static AbsoluteAllocationdeepCopy(AbsoluteAllocation template) factory method to create a deep copy of AbsoluteAllocation@NotNull @Valid HighPrecisionMoneyAmount of the Order total allocated to the Payment Method.static AbsoluteAllocationof()factory methodstatic AbsoluteAllocationof(AbsoluteAllocation template) factory method to create a shallow copy AbsoluteAllocationvoidsetAmount(HighPrecisionMoney amount) Amount of the Order total allocated to the Payment Method.static tools.jackson.core.type.TypeReference<AbsoluteAllocation>gives a TypeReference for usage with Jackson DataBinddefault <T> TwithAbsoluteAllocation(Function<AbsoluteAllocation, T> helper) accessor map functionMethods inherited from interface com.commercetools.api.models.cart.Allocation
getType, withAllocation
-
Field Details
-
ABSOLUTE
discriminator value for AbsoluteAllocation- See Also:
-
-
Method Details
-
getAmount
Amount of the Order total allocated to the Payment Method.
- Returns:
- amount
-
setAmount
Amount of the Order total allocated to the Payment Method.
- Parameters:
amount- value to be set
-
of
factory method- Returns:
- instance of AbsoluteAllocation
-
of
factory method to create a shallow copy AbsoluteAllocation- Parameters:
template- instance to be copied- Returns:
- copy instance
-
copyDeep
AbsoluteAllocation copyDeep()- Specified by:
copyDeepin interfaceAllocation
-
deepCopy
factory method to create a deep copy of AbsoluteAllocation- Parameters:
template- instance to be copied- Returns:
- copy instance
-
builder
builder factory method for AbsoluteAllocation- Returns:
- builder
-
builder
create builder for AbsoluteAllocation instance- Parameters:
template- instance with prefilled values for the builder- Returns:
- builder
-
withAbsoluteAllocation
accessor map function- Type Parameters:
T- mapped type- Parameters:
helper- function to map the object- Returns:
- mapped value
-
typeReference
gives a TypeReference for usage with Jackson DataBind- Returns:
- TypeReference
-