Interface ProductSearchFacetResultStats
- All Superinterfaces:
ProductSearchFacetResult
Result of a stats facet. The data type of min max, mean, and sum matches the data type of the field in the facet expression.
Example to create an instance using the builder pattern
ProductSearchFacetResultStats productSearchFacetResultStats = ProductSearchFacetResultStats.builder()
.name("{name}")
.count(0.3)
.build()
-
Method Summary
Modifier and TypeMethodDescriptionbuilder()builder factory method for ProductSearchFacetResultStatsbuilder(ProductSearchFacetResultStats template) create builder for ProductSearchFacetResultStats instancecopyDeep()deepCopy(ProductSearchFacetResultStats template) factory method to create a deep copy of ProductSearchFacetResultStats@NotNull LonggetCount()The total number of values counted that match the facet expression.@NotNull ObjectgetMax()The maximum value of the field, scoped to the faceted results.getMean()The average value of the field calculated assum/count.@NotNull ObjectgetMin()The minimum value of the field, scoped to the faceted results.getSum()The sum of values of the field that match the facet expression.of()factory methodof(ProductSearchFacetResultStats template) factory method to create a shallow copy ProductSearchFacetResultStatsvoidThe total number of values counted that match the facet expression.voidThe maximum value of the field, scoped to the faceted results.voidThe average value of the field calculated assum/count.voidThe minimum value of the field, scoped to the faceted results.voidThe sum of values of the field that match the facet expression.static com.fasterxml.jackson.core.type.TypeReference<ProductSearchFacetResultStats>gives a TypeReference for usage with Jackson DataBinddefault <T> Taccessor map functionMethods inherited from interface com.commercetools.api.models.product_search.ProductSearchFacetResult
getName, setName, withProductSearchFacetResult
-
Method Details
-
getMin
The minimum value of the field, scoped to the faceted results.
- Returns:
- min
-
getMax
The maximum value of the field, scoped to the faceted results.
- Returns:
- max
-
getMean
Object getMean()The average value of the field calculated as
sum/count.Only returned for number fields.
- Returns:
- mean
-
getSum
Object getSum()The sum of values of the field that match the facet expression.
Only returned for number fields.
- Returns:
- sum
-
getCount
The total number of values counted that match the facet expression.
- Returns:
- count
-
setMin
The minimum value of the field, scoped to the faceted results.
- Parameters:
min- value to be set
-
setMax
The maximum value of the field, scoped to the faceted results.
- Parameters:
max- value to be set
-
setMean
The average value of the field calculated as
sum/count.Only returned for number fields.
- Parameters:
mean- value to be set
-
setSum
The sum of values of the field that match the facet expression.
Only returned for number fields.
- Parameters:
sum- value to be set
-
setCount
The total number of values counted that match the facet expression.
- Parameters:
count- value to be set
-
of
factory method- Returns:
- instance of ProductSearchFacetResultStats
-
of
factory method to create a shallow copy ProductSearchFacetResultStats- Parameters:
template- instance to be copied- Returns:
- copy instance
-
copyDeep
ProductSearchFacetResultStats copyDeep()- Specified by:
copyDeepin interfaceProductSearchFacetResult
-
deepCopy
@Nullable static ProductSearchFacetResultStats deepCopy(@Nullable ProductSearchFacetResultStats template) factory method to create a deep copy of ProductSearchFacetResultStats- Parameters:
template- instance to be copied- Returns:
- copy instance
-
builder
builder factory method for ProductSearchFacetResultStats- Returns:
- builder
-
builder
create builder for ProductSearchFacetResultStats instance- Parameters:
template- instance with prefilled values for the builder- Returns:
- builder
-
withProductSearchFacetResultStats
accessor map function- Type Parameters:
T- mapped type- Parameters:
helper- function to map the object- Returns:
- mapped value
-
typeReference
gives a TypeReference for usage with Jackson DataBind- Returns:
- TypeReference
-