Class DuplicateStandalonePriceScopeErrorBuilder
- All Implemented Interfaces:
Builder<DuplicateStandalonePriceScopeError>
Example to create an instance using the builder pattern
DuplicateStandalonePriceScopeError duplicateStandalonePriceScopeError = DuplicateStandalonePriceScopeError.builder()
.message("{message}")
.conflictingStandalonePrice(conflictingStandalonePriceBuilder -> conflictingStandalonePriceBuilder)
.sku("{sku}")
.currency("{currency}")
.build()
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionError-specific additional fields.build()
builds DuplicateStandalonePriceScopeError with checking for non-null required valuesbuilds DuplicateStandalonePriceScopeError without checking for non-null required valueschannel
(ChannelResourceIdentifier channel) Channel for which the Standalone Price is valid.Channel for which the Standalone Price is valid.conflictingStandalonePrice
(StandalonePriceReference conflictingStandalonePrice) Reference to the conflicting Standalone Price.conflictingStandalonePrice
(Function<StandalonePriceReferenceBuilder, StandalonePriceReferenceBuilder> builder) Reference to the conflicting Standalone Price.Country code of the geographic location.Currency code of the country.customerGroup
(CustomerGroupResourceIdentifier customerGroup) CustomerGroup for which the Standalone Price is valid.customerGroup
(Function<CustomerGroupResourceIdentifierBuilder, CustomerGroupResourceIdentifierBuilder> builder) CustomerGroup for which the Standalone Price is valid.Channel for which the Standalone Price is valid.Reference to the conflicting Standalone Price.Country code of the geographic location.Currency code of the country.CustomerGroup for which the Standalone Price is valid."Duplicate standalone price scope for SKU: $sku.
getSku()
SKU of the ProductVariant to which the conflicting Standalone Price is associated.Date and time (UTC) from which the Standalone Price is valid.Date and time (UTC) until which the Standalone Price is valid.Error-specific additional fields."Duplicate standalone price scope for SKU: $sku.
of()
factory method for an instance of DuplicateStandalonePriceScopeErrorBuilderof
(DuplicateStandalonePriceScopeError template) create builder for DuplicateStandalonePriceScopeError instanceSKU of the ProductVariant to which the conflicting Standalone Price is associated.validFrom
(ZonedDateTime validFrom) Date and time (UTC) from which the Standalone Price is valid.validUntil
(ZonedDateTime validUntil) Date and time (UTC) until which the Standalone Price is valid.Error-specific additional fields.Channel for which the Standalone Price is valid.withConflictingStandalonePrice
(Function<StandalonePriceReferenceBuilder, StandalonePriceReference> builder) Reference to the conflicting Standalone Price.withCustomerGroup
(Function<CustomerGroupResourceIdentifierBuilder, CustomerGroupResourceIdentifier> builder) CustomerGroup for which the Standalone Price is valid.
-
Constructor Details
-
DuplicateStandalonePriceScopeErrorBuilder
public DuplicateStandalonePriceScopeErrorBuilder()
-
-
Method Details
-
message
"Duplicate standalone price scope for SKU: $sku. The combination of SKU, currency, country, customerGroup, channel, validFrom and validUntil must be unique for each standalone price."
- Parameters:
message
- value to be set- Returns:
- Builder
-
values
Error-specific additional fields.
- Parameters:
values
- properties to be set- Returns:
- Builder
-
addValue
Error-specific additional fields.
- Parameters:
key
- property namevalue
- property value- Returns:
- Builder
-
conflictingStandalonePrice
public DuplicateStandalonePriceScopeErrorBuilder conflictingStandalonePrice(Function<StandalonePriceReferenceBuilder, StandalonePriceReferenceBuilder> builder) Reference to the conflicting Standalone Price.
- Parameters:
builder
- function to build the conflictingStandalonePrice value- Returns:
- Builder
-
withConflictingStandalonePrice
public DuplicateStandalonePriceScopeErrorBuilder withConflictingStandalonePrice(Function<StandalonePriceReferenceBuilder, StandalonePriceReference> builder) Reference to the conflicting Standalone Price.
- Parameters:
builder
- function to build the conflictingStandalonePrice value- Returns:
- Builder
-
conflictingStandalonePrice
public DuplicateStandalonePriceScopeErrorBuilder conflictingStandalonePrice(StandalonePriceReference conflictingStandalonePrice) Reference to the conflicting Standalone Price.
- Parameters:
conflictingStandalonePrice
- value to be set- Returns:
- Builder
-
sku
SKU of the ProductVariant to which the conflicting Standalone Price is associated.
- Parameters:
sku
- value to be set- Returns:
- Builder
-
currency
Currency code of the country.
- Parameters:
currency
- value to be set- Returns:
- Builder
-
country
Country code of the geographic location.
- Parameters:
country
- value to be set- Returns:
- Builder
-
customerGroup
public DuplicateStandalonePriceScopeErrorBuilder customerGroup(Function<CustomerGroupResourceIdentifierBuilder, CustomerGroupResourceIdentifierBuilder> builder) CustomerGroup for which the Standalone Price is valid.
- Parameters:
builder
- function to build the customerGroup value- Returns:
- Builder
-
withCustomerGroup
public DuplicateStandalonePriceScopeErrorBuilder withCustomerGroup(Function<CustomerGroupResourceIdentifierBuilder, CustomerGroupResourceIdentifier> builder) CustomerGroup for which the Standalone Price is valid.
- Parameters:
builder
- function to build the customerGroup value- Returns:
- Builder
-
customerGroup
public DuplicateStandalonePriceScopeErrorBuilder customerGroup(@Nullable CustomerGroupResourceIdentifier customerGroup) CustomerGroup for which the Standalone Price is valid.
- Parameters:
customerGroup
- value to be set- Returns:
- Builder
-
channel
public DuplicateStandalonePriceScopeErrorBuilder channel(Function<ChannelResourceIdentifierBuilder, ChannelResourceIdentifierBuilder> builder) Channel for which the Standalone Price is valid.
- Parameters:
builder
- function to build the channel value- Returns:
- Builder
-
withChannel
public DuplicateStandalonePriceScopeErrorBuilder withChannel(Function<ChannelResourceIdentifierBuilder, ChannelResourceIdentifier> builder) Channel for which the Standalone Price is valid.
- Parameters:
builder
- function to build the channel value- Returns:
- Builder
-
channel
public DuplicateStandalonePriceScopeErrorBuilder channel(@Nullable ChannelResourceIdentifier channel) Channel for which the Standalone Price is valid.
- Parameters:
channel
- value to be set- Returns:
- Builder
-
validFrom
Date and time (UTC) from which the Standalone Price is valid.
- Parameters:
validFrom
- value to be set- Returns:
- Builder
-
validUntil
Date and time (UTC) until which the Standalone Price is valid.
- Parameters:
validUntil
- value to be set- Returns:
- Builder
-
getMessage
"Duplicate standalone price scope for SKU: $sku. The combination of SKU, currency, country, customerGroup, channel, validFrom and validUntil must be unique for each standalone price."
- Returns:
- message
-
getValues
Error-specific additional fields.
- Returns:
- pattern properties
-
getConflictingStandalonePrice
Reference to the conflicting Standalone Price.
- Returns:
- conflictingStandalonePrice
-
getSku
SKU of the ProductVariant to which the conflicting Standalone Price is associated.
- Returns:
- sku
-
getCurrency
Currency code of the country.
- Returns:
- currency
-
getCountry
Country code of the geographic location.
- Returns:
- country
-
getCustomerGroup
CustomerGroup for which the Standalone Price is valid.
- Returns:
- customerGroup
-
getChannel
Channel for which the Standalone Price is valid.
- Returns:
- channel
-
getValidFrom
Date and time (UTC) from which the Standalone Price is valid.
- Returns:
- validFrom
-
getValidUntil
Date and time (UTC) until which the Standalone Price is valid.
- Returns:
- validUntil
-
build
builds DuplicateStandalonePriceScopeError with checking for non-null required values- Specified by:
build
in interfaceBuilder<DuplicateStandalonePriceScopeError>
- Returns:
- DuplicateStandalonePriceScopeError
-
buildUnchecked
builds DuplicateStandalonePriceScopeError without checking for non-null required values- Returns:
- DuplicateStandalonePriceScopeError
-
of
factory method for an instance of DuplicateStandalonePriceScopeErrorBuilder- Returns:
- builder
-
of
public static DuplicateStandalonePriceScopeErrorBuilder of(DuplicateStandalonePriceScopeError template) create builder for DuplicateStandalonePriceScopeError instance- Parameters:
template
- instance with prefilled values for the builder- Returns:
- builder
-