Class TaxedItemPriceDraftBuilder
java.lang.Object
com.commercetools.api.models.order.TaxedItemPriceDraftBuilder
- All Implemented Interfaces:
Builder<TaxedItemPriceDraft>
TaxedItemPriceDraftBuilder
Example to create an instance using the builder pattern
Example to create an instance using the builder pattern
TaxedItemPriceDraft taxedItemPriceDraft = TaxedItemPriceDraft.builder()
.totalNet(totalNetBuilder -> totalNetBuilder)
.totalGross(totalGrossBuilder -> totalGrossBuilder)
.build()
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()builds TaxedItemPriceDraft with checking for non-null required valuesbuilds TaxedItemPriceDraft without checking for non-null required valuesDraft object to store money in cent amounts for a specific currency.Draft object to store money in cent amounts for a specific currency.static TaxedItemPriceDraftBuilderof()factory method for an instance of TaxedItemPriceDraftBuilderstatic TaxedItemPriceDraftBuilderof(TaxedItemPriceDraft template) create builder for TaxedItemPriceDraft instancetotalGross(Money totalGross) Draft object to store money in cent amounts for a specific currency.totalGross(Function<MoneyBuilder, MoneyBuilder> builder) Draft object to store money in cent amounts for a specific currency.Draft object to store money in cent amounts for a specific currency.totalNet(Function<MoneyBuilder, MoneyBuilder> builder) Draft object to store money in cent amounts for a specific currency.withTotalGross(Function<MoneyBuilder, Money> builder) Draft object to store money in cent amounts for a specific currency.withTotalNet(Function<MoneyBuilder, Money> builder) Draft object to store money in cent amounts for a specific currency.
-
Constructor Details
-
TaxedItemPriceDraftBuilder
public TaxedItemPriceDraftBuilder()
-
-
Method Details
-
totalNet
Draft object to store money in cent amounts for a specific currency.
- Parameters:
builder- function to build the totalNet value- Returns:
- Builder
-
withTotalNet
Draft object to store money in cent amounts for a specific currency.
- Parameters:
builder- function to build the totalNet value- Returns:
- Builder
-
totalNet
Draft object to store money in cent amounts for a specific currency.
- Parameters:
totalNet- value to be set- Returns:
- Builder
-
totalGross
Draft object to store money in cent amounts for a specific currency.
- Parameters:
builder- function to build the totalGross value- Returns:
- Builder
-
withTotalGross
Draft object to store money in cent amounts for a specific currency.
- Parameters:
builder- function to build the totalGross value- Returns:
- Builder
-
totalGross
Draft object to store money in cent amounts for a specific currency.
- Parameters:
totalGross- value to be set- Returns:
- Builder
-
getTotalNet
Draft object to store money in cent amounts for a specific currency.
- Returns:
- totalNet
-
getTotalGross
Draft object to store money in cent amounts for a specific currency.
- Returns:
- totalGross
-
build
builds TaxedItemPriceDraft with checking for non-null required values- Specified by:
buildin interfaceBuilder<TaxedItemPriceDraft>- Returns:
- TaxedItemPriceDraft
-
buildUnchecked
builds TaxedItemPriceDraft without checking for non-null required values- Returns:
- TaxedItemPriceDraft
-
of
factory method for an instance of TaxedItemPriceDraftBuilder- Returns:
- builder
-
of
create builder for TaxedItemPriceDraft instance- Parameters:
template- instance with prefilled values for the builder- Returns:
- builder
-