Package ddf.catalog.operation.impl
Class FacetAttributeResultImpl
java.lang.Object
ddf.catalog.operation.impl.FacetAttributeResultImpl
- All Implemented Interfaces:
ddf.catalog.operation.FacetAttributeResult
public class FacetAttributeResultImpl
extends Object
implements ddf.catalog.operation.FacetAttributeResult
-
Constructor Summary
ConstructorsConstructorDescriptionFacetAttributeResultImpl(String attributeName, List<String> attributeValues, List<Long> valueCounts) Instantiates a FacetAttributeResultImpl representing a portion of the results of a faceted query.FacetAttributeResultImpl(String attributeName, List<org.apache.commons.lang3.tuple.Pair<String, Long>> valueCountPairs) Instantiates a FacetAttributeResultImpl representing a portion of the results of a faceted query. -
Method Summary
-
Constructor Details
-
FacetAttributeResultImpl
public FacetAttributeResultImpl(String attributeName, List<String> attributeValues, List<Long> valueCounts) Instantiates a FacetAttributeResultImpl representing a portion of the results of a faceted query. A FacetAttributeResultImpl is representative of a single attribute's faceting results, and zero to manyFacetAttributeResults may make up a complete faceted query result. This constructor zips together the attributeValues and valueCounts provided, and these list should correspond and be of the same length if sane results are desired.- Parameters:
attributeName- The attribute name for which faceting data is reportedattributeValues- A list of the discovered facet valuesvalueCounts- A list of the number of occurrences for each facet value
-
FacetAttributeResultImpl
public FacetAttributeResultImpl(String attributeName, List<org.apache.commons.lang3.tuple.Pair<String, Long>> valueCountPairs) Instantiates a FacetAttributeResultImpl representing a portion of the results of a faceted query. This constructor takes a zipped list of value to count pairings.- Parameters:
attributeName- The field name for which faceting data is reportedvalueCountPairs- A list of value-count pairs for the faceted field
-
-
Method Details
-
getAttributeName
- Specified by:
getAttributeNamein interfaceddf.catalog.operation.FacetAttributeResult
-
getFacetValues
- Specified by:
getFacetValuesin interfaceddf.catalog.operation.FacetAttributeResult
-