Class PriceDraftImportBuilder
- All Implemented Interfaces:
Builder<PriceDraftImport>
Example to create an instance using the builder pattern
PriceDraftImport priceDraftImport = PriceDraftImport.builder()
.value(valueBuilder -> valueBuilder)
.key("{key}")
.build()
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionaddTiers
(Function<PriceTierBuilder, PriceTier> builder) The tiered prices for this price.build()
builds PriceDraftImport with checking for non-null required valuesbuilds PriceDraftImport without checking for non-null required valueschannel
(ChannelKeyReference channel) References a channel by key.References a channel by key.A two-digit country code as per ISO 3166-1 alpha-2.The custom fields for this category.custom
(Function<CustomBuilder, CustomBuilder> builder) The custom fields for this category.customerGroup
(CustomerGroupKeyReference customerGroup) References a customer group by key.References a customer group by key.discounted
(DiscountedPrice discounted) Sets a discounted price from an external service.Sets a discounted price from an external service.References a channel by key.A two-digit country code as per ISO 3166-1 alpha-2.The custom fields for this category.References a customer group by key.Sets a discounted price from an external service.getKey()
User-defined unique identifier for the Embedded Price.getTiers()
The tiered prices for this price.value of validFrom}value of validUntil}getValue()
value of value}User-defined unique identifier for the Embedded Price.static PriceDraftImportBuilder
of()
factory method for an instance of PriceDraftImportBuilderstatic PriceDraftImportBuilder
of
(PriceDraftImport template) create builder for PriceDraftImport instanceThe tiered prices for this price.plusTiers
(Function<PriceTierBuilder, PriceTierBuilder> builder) The tiered prices for this price.setTiers
(Function<PriceTierBuilder, PriceTier> builder) The tiered prices for this price.The tiered prices for this price.The tiered prices for this price.validFrom
(ZonedDateTime validFrom) set the value to the validFromvalidUntil
(ZonedDateTime validUntil) set the value to the validUntilvalue
(TypedMoney value) set the value to the valuevalue
(Function<TypedMoneyBuilder, Builder<? extends TypedMoney>> builder) set the value to the value using the builder functionReferences a channel by key.withCustom
(Function<CustomBuilder, Custom> builder) The custom fields for this category.References a customer group by key.Sets a discounted price from an external service.withTiers
(Function<PriceTierBuilder, PriceTierBuilder> builder) The tiered prices for this price.
-
Constructor Details
-
PriceDraftImportBuilder
public PriceDraftImportBuilder()
-
-
Method Details
-
value
set the value to the value- Parameters:
value
- value to be set- Returns:
- Builder
-
value
public PriceDraftImportBuilder value(Function<TypedMoneyBuilder, Builder<? extends TypedMoney>> builder) set the value to the value using the builder function- Parameters:
builder
- function to build the value value- Returns:
- Builder
-
country
A two-digit country code as per ISO 3166-1 alpha-2.
- Parameters:
country
- value to be set- Returns:
- Builder
-
customerGroup
public PriceDraftImportBuilder customerGroup(Function<CustomerGroupKeyReferenceBuilder, CustomerGroupKeyReferenceBuilder> builder) References a customer group by key.
- Parameters:
builder
- function to build the customerGroup value- Returns:
- Builder
-
withCustomerGroup
public PriceDraftImportBuilder withCustomerGroup(Function<CustomerGroupKeyReferenceBuilder, CustomerGroupKeyReference> builder) References a customer group by key.
- Parameters:
builder
- function to build the customerGroup value- Returns:
- Builder
-
customerGroup
References a customer group by key.
- Parameters:
customerGroup
- value to be set- Returns:
- Builder
-
channel
public PriceDraftImportBuilder channel(Function<ChannelKeyReferenceBuilder, ChannelKeyReferenceBuilder> builder) References a channel by key.
- Parameters:
builder
- function to build the channel value- Returns:
- Builder
-
withChannel
public PriceDraftImportBuilder withChannel(Function<ChannelKeyReferenceBuilder, ChannelKeyReference> builder) References a channel by key.
- Parameters:
builder
- function to build the channel value- Returns:
- Builder
-
channel
References a channel by key.
- Parameters:
channel
- value to be set- Returns:
- Builder
-
validFrom
set the value to the validFrom- Parameters:
validFrom
- value to be set- Returns:
- Builder
-
validUntil
set the value to the validUntil- Parameters:
validUntil
- value to be set- Returns:
- Builder
-
custom
The custom fields for this category.
- Parameters:
builder
- function to build the custom value- Returns:
- Builder
-
withCustom
The custom fields for this category.
- Parameters:
builder
- function to build the custom value- Returns:
- Builder
-
custom
The custom fields for this category.
- Parameters:
custom
- value to be set- Returns:
- Builder
-
discounted
public PriceDraftImportBuilder discounted(Function<DiscountedPriceBuilder, DiscountedPriceBuilder> builder) Sets a discounted price from an external service.
- Parameters:
builder
- function to build the discounted value- Returns:
- Builder
-
withDiscounted
public PriceDraftImportBuilder withDiscounted(Function<DiscountedPriceBuilder, DiscountedPrice> builder) Sets a discounted price from an external service.
- Parameters:
builder
- function to build the discounted value- Returns:
- Builder
-
discounted
Sets a discounted price from an external service.
- Parameters:
discounted
- value to be set- Returns:
- Builder
-
tiers
The tiered prices for this price.
- Parameters:
tiers
- value to be set- Returns:
- Builder
-
tiers
The tiered prices for this price.
- Parameters:
tiers
- value to be set- Returns:
- Builder
-
plusTiers
The tiered prices for this price.
- Parameters:
tiers
- value to be set- Returns:
- Builder
-
plusTiers
The tiered prices for this price.
- Parameters:
builder
- function to build the tiers value- Returns:
- Builder
-
withTiers
The tiered prices for this price.
- Parameters:
builder
- function to build the tiers value- Returns:
- Builder
-
addTiers
The tiered prices for this price.
- Parameters:
builder
- function to build the tiers value- Returns:
- Builder
-
setTiers
The tiered prices for this price.
- Parameters:
builder
- function to build the tiers value- Returns:
- Builder
-
key
User-defined unique identifier for the Embedded Price.
- Parameters:
key
- value to be set- Returns:
- Builder
-
getValue
value of value}- Returns:
- value
-
getCountry
A two-digit country code as per ISO 3166-1 alpha-2.
- Returns:
- country
-
getCustomerGroup
References a customer group by key.
- Returns:
- customerGroup
-
getChannel
References a channel by key.
- Returns:
- channel
-
getValidFrom
value of validFrom}- Returns:
- validFrom
-
getValidUntil
value of validUntil}- Returns:
- validUntil
-
getCustom
The custom fields for this category.
- Returns:
- custom
-
getDiscounted
Sets a discounted price from an external service.
- Returns:
- discounted
-
getTiers
The tiered prices for this price.
- Returns:
- tiers
-
getKey
User-defined unique identifier for the Embedded Price.
- Returns:
- key
-
build
builds PriceDraftImport with checking for non-null required values- Specified by:
build
in interfaceBuilder<PriceDraftImport>
- Returns:
- PriceDraftImport
-
buildUnchecked
builds PriceDraftImport without checking for non-null required values- Returns:
- PriceDraftImport
-
of
factory method for an instance of PriceDraftImportBuilder- Returns:
- builder
-
of
create builder for PriceDraftImport instance- Parameters:
template
- instance with prefilled values for the builder- Returns:
- builder
-