Class ProductPresentWithDifferentVariantSelectionErrorBuilder
- All Implemented Interfaces:
Builder<ProductPresentWithDifferentVariantSelectionError>
Example to create an instance using the builder pattern
ProductPresentWithDifferentVariantSelectionError productPresentWithDifferentVariantSelectionError = ProductPresentWithDifferentVariantSelectionError.builder()
.message("{message}")
.product(productBuilder -> productBuilder)
.existingVariantSelection(existingVariantSelectionBuilder -> existingVariantSelectionBuilder)
.build()
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionError-specific additional fields.build()
builds ProductPresentWithDifferentVariantSelectionError with checking for non-null required valuesbuilds ProductPresentWithDifferentVariantSelectionError without checking for non-null required valuesexistingVariantSelection
(ProductVariantSelection existingVariantSelection) Existing Product Variant Selection or Exclusion for the Product in the Product Selection.existingVariantSelection
(Function<ProductVariantSelectionBuilder, Builder<? extends ProductVariantSelection>> builder) Existing Product Variant Selection or Exclusion for the Product in the Product Selection.Existing Product Variant Selection or Exclusion for the Product in the Product Selection."Product is already present with the following different $variantSelections."
Reference to the Product for which the error was returned.Error-specific additional fields."Product is already present with the following different $variantSelections."
of()
factory method for an instance of ProductPresentWithDifferentVariantSelectionErrorBuildercreate builder for ProductPresentWithDifferentVariantSelectionError instanceproduct
(ProductReference product) Reference to the Product for which the error was returned.Reference to the Product for which the error was returned.Error-specific additional fields.Reference to the Product for which the error was returned.
-
Constructor Details
-
ProductPresentWithDifferentVariantSelectionErrorBuilder
public ProductPresentWithDifferentVariantSelectionErrorBuilder()
-
-
Method Details
-
message
"Product is already present with the following different $variantSelections."
- 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
-
product
public ProductPresentWithDifferentVariantSelectionErrorBuilder product(Function<ProductReferenceBuilder, ProductReferenceBuilder> builder) Reference to the Product for which the error was returned.
- Parameters:
builder
- function to build the product value- Returns:
- Builder
-
withProduct
public ProductPresentWithDifferentVariantSelectionErrorBuilder withProduct(Function<ProductReferenceBuilder, ProductReference> builder) Reference to the Product for which the error was returned.
- Parameters:
builder
- function to build the product value- Returns:
- Builder
-
product
Reference to the Product for which the error was returned.
- Parameters:
product
- value to be set- Returns:
- Builder
-
existingVariantSelection
public ProductPresentWithDifferentVariantSelectionErrorBuilder existingVariantSelection(ProductVariantSelection existingVariantSelection) Existing Product Variant Selection or Exclusion for the Product in the Product Selection.
- Parameters:
existingVariantSelection
- value to be set- Returns:
- Builder
-
existingVariantSelection
public ProductPresentWithDifferentVariantSelectionErrorBuilder existingVariantSelection(Function<ProductVariantSelectionBuilder, Builder<? extends ProductVariantSelection>> builder) Existing Product Variant Selection or Exclusion for the Product in the Product Selection.
- Parameters:
builder
- function to build the existingVariantSelection value- Returns:
- Builder
-
getMessage
"Product is already present with the following different $variantSelections."
- Returns:
- message
-
getValues
Error-specific additional fields.
- Returns:
- pattern properties
-
getProduct
Reference to the Product for which the error was returned.
- Returns:
- product
-
getExistingVariantSelection
Existing Product Variant Selection or Exclusion for the Product in the Product Selection.
- Returns:
- existingVariantSelection
-
build
builds ProductPresentWithDifferentVariantSelectionError with checking for non-null required values- Specified by:
build
in interfaceBuilder<ProductPresentWithDifferentVariantSelectionError>
- Returns:
- ProductPresentWithDifferentVariantSelectionError
-
buildUnchecked
builds ProductPresentWithDifferentVariantSelectionError without checking for non-null required values- Returns:
- ProductPresentWithDifferentVariantSelectionError
-
of
factory method for an instance of ProductPresentWithDifferentVariantSelectionErrorBuilder- Returns:
- builder
-
of
public static ProductPresentWithDifferentVariantSelectionErrorBuilder of(ProductPresentWithDifferentVariantSelectionError template) create builder for ProductPresentWithDifferentVariantSelectionError instance- Parameters:
template
- instance with prefilled values for the builder- Returns:
- builder
-