Class ProductFilterResult
java.lang.Object
de.hybris.platform.classification.filter.ProductFilterResult
The result you get when you have applied a product filter. It contains the list of the filtered products and also a
list of all possible attribute values for these products.
-
Constructor Summary
ConstructorsConstructorDescriptionProductFilterResult(List<ProductModel> products, List<FilterAttribute> filteredAttributes, int totalCount) Initializes a result with a list of products and a list of possible filter attributes. -
Method Summary
Modifier and TypeMethodDescriptionintgetCount()The number of elements in the result list.A list of possible attribute values for the filtered products.Returns the list of the filtered products.intThe total number of products for the filter.
-
Constructor Details
-
ProductFilterResult
public ProductFilterResult(List<ProductModel> products, List<FilterAttribute> filteredAttributes, int totalCount) Initializes a result with a list of products and a list of possible filter attributes.
-
-
Method Details
-
getProducts
Returns the list of the filtered products.- Returns:
- the list of the filtered products
-
getFilteredAttributes
A list of possible attribute values for the filtered products. Each item represents a classifcation attribute and a list of possible values, but only those values that can be found in the filtered products. Values that have been used in the filter are marked with a flag. You can use this information to construct a new filter with which you can further drill down the result, e.g. with a funnel search.- Returns:
- a list of possible filter attributes
- See Also:
-
getCount
public int getCount()The number of elements in the result list. This may be less that thetotal countif you have limited the result list.- Returns:
- the number of elements in the result list
-
getTotalCount
public int getTotalCount()The total number of products for the filter. This may be more than thecountif you have limited the result lost- Returns:
- the total number of products for the filter
-