Class FacetResultsBuilder
java.lang.Object
com.commercetools.api.models.product.FacetResultsBuilder
- All Implemented Interfaces:
Builder<FacetResults>
FacetResultsBuilder
Example to create an instance using the builder pattern
Example to create an instance using the builder pattern
FacetResults facetResults = FacetResults.builder()
./^[a-z].*$/(/^[a-z].*$/Builder -> /^[a-z].*$/Builder)
.build()
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionaddValue
(String key, FacetResult value) assign a pattern property to the builderbuild()
builds FacetResults with checking for non-null required valuesbuilds FacetResults without checking for non-null required valuesvalues of pattern propertiesstatic FacetResultsBuilder
of()
factory method for an instance of FacetResultsBuilderstatic FacetResultsBuilder
of
(FacetResults template) create builder for FacetResults instancevalues
(Map<String, FacetResult> values) assign pattern properties to the builder
-
Constructor Details
-
FacetResultsBuilder
public FacetResultsBuilder()
-
-
Method Details
-
values
assign pattern properties to the builder- Parameters:
values
- properties to be set- Returns:
- Builder
-
addValue
assign a pattern property to the builder- Parameters:
key
- property namevalue
- property value- Returns:
- Builder
-
getValues
values of pattern properties- Returns:
- pattern properties
-
build
builds FacetResults with checking for non-null required values- Specified by:
build
in interfaceBuilder<FacetResults>
- Returns:
- FacetResults
-
buildUnchecked
builds FacetResults without checking for non-null required values- Returns:
- FacetResults
-
of
factory method for an instance of FacetResultsBuilder- Returns:
- builder
-
of
create builder for FacetResults instance- Parameters:
template
- instance with prefilled values for the builder- Returns:
- builder
-