org.apache.lucene.facet.old
Class AdaptiveFacetsAccumulator

java.lang.Object
  extended by org.apache.lucene.facet.search.FacetsAccumulator
      extended by org.apache.lucene.facet.search.TaxonomyFacetsAccumulator
          extended by org.apache.lucene.facet.old.OldFacetsAccumulator
              extended by org.apache.lucene.facet.old.AdaptiveFacetsAccumulator

public final class AdaptiveFacetsAccumulator
extends OldFacetsAccumulator

FacetsAccumulator whose behavior regarding complements, sampling, etc. is not set up front but rather is determined at accumulation time according to the statistics of the accumulated set of documents and the index.

Note: Sampling accumulation (Accumulation over a sampled-set of the results), does not guarantee accurate values for FacetResult.getNumValidDescendants().

WARNING: This API is experimental and might change in incompatible ways in the next release.

Field Summary
 
Fields inherited from class org.apache.lucene.facet.old.OldFacetsAccumulator
DEFAULT_COMPLEMENT_THRESHOLD, DISABLE_COMPLEMENT, FORCE_COMPLEMENT, isUsingComplements, maxPartitions, partitionSize
 
Fields inherited from class org.apache.lucene.facet.search.TaxonomyFacetsAccumulator
facetArrays, indexReader, taxonomyReader
 
Fields inherited from class org.apache.lucene.facet.search.FacetsAccumulator
searchParams
 
Constructor Summary
AdaptiveFacetsAccumulator(FacetSearchParams searchParams, IndexReader indexReader, TaxonomyReader taxonomyReader)
          Create an AdaptiveFacetsAccumulator
AdaptiveFacetsAccumulator(FacetSearchParams searchParams, IndexReader indexReader, TaxonomyReader taxonomyReader, FacetArrays facetArrays)
          Create an AdaptiveFacetsAccumulator
 
Method Summary
 List<FacetResult> accumulate(ScoredDocIDs docids)
           
 Sampler getSampler()
           
 void setSampler(Sampler sampler)
          Set the sampler.
 
Methods inherited from class org.apache.lucene.facet.old.OldFacetsAccumulator
accumulate, actualDocsToAccumulate, createAggregator, createFacetResultsHandler, createOrdinalValueResolver, getCategoryListMap, getComplementThreshold, getTotalCountsFactor, isUsingComplements, mayComplement, setComplementThreshold, shouldComplement
 
Methods inherited from class org.apache.lucene.facet.search.TaxonomyFacetsAccumulator
getAggregator, groupRequests, requiresDocScores
 
Methods inherited from class org.apache.lucene.facet.search.FacetsAccumulator
create, create, emptyResult
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AdaptiveFacetsAccumulator

public AdaptiveFacetsAccumulator(FacetSearchParams searchParams,
                                 IndexReader indexReader,
                                 TaxonomyReader taxonomyReader)
Create an AdaptiveFacetsAccumulator

See Also:
OldFacetsAccumulator.OldFacetsAccumulator(FacetSearchParams, IndexReader, TaxonomyReader)

AdaptiveFacetsAccumulator

public AdaptiveFacetsAccumulator(FacetSearchParams searchParams,
                                 IndexReader indexReader,
                                 TaxonomyReader taxonomyReader,
                                 FacetArrays facetArrays)
Create an AdaptiveFacetsAccumulator

See Also:
OldFacetsAccumulator.OldFacetsAccumulator(FacetSearchParams, IndexReader, TaxonomyReader, FacetArrays)
Method Detail

setSampler

public void setSampler(Sampler sampler)
Set the sampler.

Parameters:
sampler - sampler to set

accumulate

public List<FacetResult> accumulate(ScoredDocIDs docids)
                             throws IOException
Overrides:
accumulate in class OldFacetsAccumulator
Throws:
IOException

getSampler

public final Sampler getSampler()
Returns:
the sampler in effect


Copyright © 2000-2013 Apache Software Foundation. All Rights Reserved.