Interface FacetCutter
-
- All Known Implementing Classes:
DoubleRangeFacetCutter
,LongRangeFacetCutter
,LongValueFacetCutter
,TaxonomyFacetsCutter
public interface FacetCutter
CreatesLeafFacetCutter
for each leaf.TODO: do we need FacetCutterManager similar to CollectorManager, e.g. is createLeafCutter always thread safe?
- WARNING: This API is experimental and might change in incompatible ways in the next release.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description LeafFacetCutter
createLeafCutter(LeafReaderContext context)
Get cutter for the leaf.default OrdinalIterator
getChildrenOrds(int ord)
For facets that have hierarchy (levels), get all children ordinals for given ord.default OrdinalIterator
getOrdinalsToRollup()
For facets that have hierarchy (levels), return all top level dimension ordinals that require rollup.
-
-
-
Method Detail
-
createLeafCutter
LeafFacetCutter createLeafCutter(LeafReaderContext context) throws IOException
Get cutter for the leaf.- Throws:
IOException
-
getOrdinalsToRollup
default OrdinalIterator getOrdinalsToRollup() throws IOException
For facets that have hierarchy (levels), return all top level dimension ordinals that require rollup.Rollup is an optimization for facets types that support hierarchy, if single document belongs to at most one node in the hierarchy, we can first record data for these nodes only, and then roll up values to parent ordinals.
Default implementation returns null, which means that rollup is not needed.
- Throws:
IOException
-
getChildrenOrds
default OrdinalIterator getChildrenOrds(int ord) throws IOException
For facets that have hierarchy (levels), get all children ordinals for given ord.- Throws:
IOException
-
-