All Known Implementing Classes:
DoubleRangeFacetCutter, LongRangeFacetCutter, LongValueFacetCutter, NonOverlappingLongRangeFacetCutter, OverlappingLongRangeFacetCutter, TaxonomyFacetsCutter

public interface FacetCutter
Creates LeafFacetCutter for each leaf.

TODO: do we need FacetCutterManager similar to CollectorManager, e.g. is createLeafCutter always thread safe?

  • Method Details

    • 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