Class GroupFacetCollector.GroupedFacetResult
- java.lang.Object
-
- org.apache.lucene.search.grouping.GroupFacetCollector.GroupedFacetResult
-
- Enclosing class:
- GroupFacetCollector
public static class GroupFacetCollector.GroupedFacetResult extends java.lang.ObjectThe grouped facet result. Containing grouped facet entries, total count and total missing count.
-
-
Field Summary
Fields Modifier and Type Field Description private intcurrentMinprivate java.util.NavigableSet<GroupFacetCollector.FacetEntry>facetEntriesprivate intmaxSizeprivate static java.util.Comparator<GroupFacetCollector.FacetEntry>orderByCountAndValueprivate static java.util.Comparator<GroupFacetCollector.FacetEntry>orderByValueprivate inttotalCountprivate inttotalMissingCount
-
Constructor Summary
Constructors Constructor Description GroupedFacetResult(int size, int minCount, boolean orderByCount, int totalCount, int totalMissingCount)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddFacetCount(BytesRef facetValue, int count)java.util.List<GroupFacetCollector.FacetEntry>getFacetEntries(int offset, int limit)Returns a list of facet entries to be rendered based on the specified offset and limit.intgetTotalCount()Returns the sum of all facet entries counts.intgetTotalMissingCount()Returns the number of groups that didn't have a facet value.
-
-
-
Field Detail
-
orderByCountAndValue
private static final java.util.Comparator<GroupFacetCollector.FacetEntry> orderByCountAndValue
-
orderByValue
private static final java.util.Comparator<GroupFacetCollector.FacetEntry> orderByValue
-
maxSize
private final int maxSize
-
facetEntries
private final java.util.NavigableSet<GroupFacetCollector.FacetEntry> facetEntries
-
totalMissingCount
private final int totalMissingCount
-
totalCount
private final int totalCount
-
currentMin
private int currentMin
-
-
Method Detail
-
addFacetCount
public void addFacetCount(BytesRef facetValue, int count)
-
getFacetEntries
public java.util.List<GroupFacetCollector.FacetEntry> getFacetEntries(int offset, int limit)
Returns a list of facet entries to be rendered based on the specified offset and limit. The facet entries are retrieved from the facet entries collected during merging.- Parameters:
offset- The offset in the collected facet entries during merginglimit- The number of facets to return starting from the offset.- Returns:
- a list of facet entries to be rendered based on the specified offset and limit
-
getTotalCount
public int getTotalCount()
Returns the sum of all facet entries counts.- Returns:
- the sum of all facet entries counts
-
getTotalMissingCount
public int getTotalMissingCount()
Returns the number of groups that didn't have a facet value.- Returns:
- the number of groups that didn't have a facet value
-
-