Class SimilarProductMetaBuilder
- All Implemented Interfaces:
Builder<SimilarProductMeta>
Example to create an instance using the builder pattern
SimilarProductMeta similarProductMeta = SimilarProductMeta.builder()
.build()
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionbuild()
builds SimilarProductMeta with checking for non-null required valuesbuilds SimilarProductMeta without checking for non-null required valuesdescription
(LocalizedString description) Localized product description used for similarity estimation.Localized product description used for similarity estimation.Localized product description used for similarity estimation.getName()
Localized product name used for similarity estimation.getPrice()
The product price in cents using the currency defined in SimilarProductSearchRequest If multiple prices exist, the median value is taken as a representative amount.Total number of variants associated with the product.name
(LocalizedString name) Localized product name used for similarity estimation.Localized product name used for similarity estimation.static SimilarProductMetaBuilder
of()
factory method for an instance of SimilarProductMetaBuilderstatic SimilarProductMetaBuilder
of
(SimilarProductMeta template) create builder for SimilarProductMeta instanceThe product price in cents using the currency defined in SimilarProductSearchRequest If multiple prices exist, the median value is taken as a representative amount.price
(Function<MoneyBuilder, MoneyBuilder> builder) The product price in cents using the currency defined in SimilarProductSearchRequest If multiple prices exist, the median value is taken as a representative amount.variantCount
(Long variantCount) Total number of variants associated with the product.Localized product description used for similarity estimation.Localized product name used for similarity estimation.withPrice
(Function<MoneyBuilder, Money> builder) The product price in cents using the currency defined in SimilarProductSearchRequest If multiple prices exist, the median value is taken as a representative amount.
-
Constructor Details
-
SimilarProductMetaBuilder
public SimilarProductMetaBuilder()
-
-
Method Details
-
name
public SimilarProductMetaBuilder name(Function<LocalizedStringBuilder, LocalizedStringBuilder> builder) Localized product name used for similarity estimation.
- Parameters:
builder
- function to build the name value- Returns:
- Builder
-
withName
Localized product name used for similarity estimation.
- Parameters:
builder
- function to build the name value- Returns:
- Builder
-
name
Localized product name used for similarity estimation.
- Parameters:
name
- value to be set- Returns:
- Builder
-
description
public SimilarProductMetaBuilder description(Function<LocalizedStringBuilder, LocalizedStringBuilder> builder) Localized product description used for similarity estimation.
- Parameters:
builder
- function to build the description value- Returns:
- Builder
-
withDescription
public SimilarProductMetaBuilder withDescription(Function<LocalizedStringBuilder, LocalizedString> builder) Localized product description used for similarity estimation.
- Parameters:
builder
- function to build the description value- Returns:
- Builder
-
description
Localized product description used for similarity estimation.
- Parameters:
description
- value to be set- Returns:
- Builder
-
price
The product price in cents using the currency defined in SimilarProductSearchRequest If multiple prices exist, the median value is taken as a representative amount.
- Parameters:
builder
- function to build the price value- Returns:
- Builder
-
withPrice
The product price in cents using the currency defined in SimilarProductSearchRequest If multiple prices exist, the median value is taken as a representative amount.
- Parameters:
builder
- function to build the price value- Returns:
- Builder
-
price
The product price in cents using the currency defined in SimilarProductSearchRequest If multiple prices exist, the median value is taken as a representative amount.
- Parameters:
price
- value to be set- Returns:
- Builder
-
variantCount
Total number of variants associated with the product.
- Parameters:
variantCount
- value to be set- Returns:
- Builder
-
getName
Localized product name used for similarity estimation.
- Returns:
- name
-
getDescription
Localized product description used for similarity estimation.
- Returns:
- description
-
getPrice
The product price in cents using the currency defined in SimilarProductSearchRequest If multiple prices exist, the median value is taken as a representative amount.
- Returns:
- price
-
getVariantCount
Total number of variants associated with the product.
- Returns:
- variantCount
-
build
builds SimilarProductMeta with checking for non-null required values- Specified by:
build
in interfaceBuilder<SimilarProductMeta>
- Returns:
- SimilarProductMeta
-
buildUnchecked
builds SimilarProductMeta without checking for non-null required values- Returns:
- SimilarProductMeta
-
of
factory method for an instance of SimilarProductMetaBuilder- Returns:
- builder
-
of
create builder for SimilarProductMeta instance- Parameters:
template
- instance with prefilled values for the builder- Returns:
- builder
-