org.apache.lucene.facet.sortedset
Class SortedSetDocValuesAccumulator

java.lang.Object
  extended by org.apache.lucene.facet.search.FacetsAccumulator
      extended by org.apache.lucene.facet.sortedset.SortedSetDocValuesAccumulator

public class SortedSetDocValuesAccumulator
extends FacetsAccumulator

A TaxonomyFacetsAccumulator that uses previously indexed SortedSetDocValuesFacetFields to perform faceting, without require a separate taxonomy index. Faceting is a bit slower (~25%), and there is added cost on every IndexReader open to create a new SortedSetDocValuesReaderState. Furthermore, this does not support hierarchical facets; only flat (dimension + label) facets, but it uses quite a bit less RAM to do so.


Field Summary
 
Fields inherited from class org.apache.lucene.facet.search.FacetsAccumulator
searchParams
 
Constructor Summary
SortedSetDocValuesAccumulator(SortedSetDocValuesReaderState state, FacetSearchParams fsp)
          Constructor with the given facet search params.
SortedSetDocValuesAccumulator(SortedSetDocValuesReaderState state, FacetSearchParams fsp, FacetArrays arrays)
           
 
Method Summary
 List<FacetResult> accumulate(List<FacetsCollector.MatchingDocs> matchingDocs)
          Used by FacetsCollector to build the list of facet results that match the facet requests that were given in the constructor.
 boolean requiresDocScores()
          Used by FacetsCollector to determine if document scores need to be collected in addition to matching documents.
 
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

SortedSetDocValuesAccumulator

public SortedSetDocValuesAccumulator(SortedSetDocValuesReaderState state,
                                     FacetSearchParams fsp)
                              throws IOException
Constructor with the given facet search params.

Throws:
IOException

SortedSetDocValuesAccumulator

public SortedSetDocValuesAccumulator(SortedSetDocValuesReaderState state,
                                     FacetSearchParams fsp,
                                     FacetArrays arrays)
                              throws IOException
Throws:
IOException
Method Detail

accumulate

public List<FacetResult> accumulate(List<FacetsCollector.MatchingDocs> matchingDocs)
                             throws IOException
Description copied from class: FacetsAccumulator
Used by FacetsCollector to build the list of facet results that match the facet requests that were given in the constructor.

Specified by:
accumulate in class FacetsAccumulator
Parameters:
matchingDocs - the documents that matched the query, per-segment.
Throws:
IOException

requiresDocScores

public boolean requiresDocScores()
Description copied from class: FacetsAccumulator
Used by FacetsCollector to determine if document scores need to be collected in addition to matching documents.

Specified by:
requiresDocScores in class FacetsAccumulator


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