Package org.apache.lucene.facet.search

Examples of org.apache.lucene.facet.search.TopKFacetResultsHandler


  @Override
  public PartitionsFacetResultsHandler createFacetResultsHandler(FacetRequest fr, OrdinalValueResolver resolver) {
    if (fr.getResultMode() == ResultMode.PER_NODE_IN_TREE) {
      return new TopKInEachNodeHandler(taxonomyReader, fr, resolver, facetArrays);
    } else {
      return new TopKFacetResultsHandler(taxonomyReader, fr, resolver, facetArrays);
    }
  }
View Full Code Here


  public FacetResultsHandler createFacetResultsHandler(TaxonomyReader taxonomyReader) {
    try {
      if (resultMode == ResultMode.PER_NODE_IN_TREE) {
        return new TopKInEachNodeHandler(taxonomyReader, (FacetRequest) clone());
      }
      return new TopKFacetResultsHandler(taxonomyReader, (FacetRequest) clone());
    } catch (CloneNotSupportedException e) {
      // Shouldn't happen since we implement Cloneable. If it does happen, it is
      // probably because the class was changed to not implement Cloneable
      // anymore.
      throw new RuntimeException(e);
View Full Code Here

   
    @Override
    /** Override this method just for verifying that only specified facets are iterated.. */
    public FacetResultsHandler createFacetResultsHandler(
        TaxonomyReader taxonomyReader) {
      return new TopKFacetResultsHandler(taxonomyReader, this) {
        @Override
        public IntermediateFacetResult fetchPartitionResult(
            FacetArrays facetArrays, int offset) throws IOException {
          final IntermediateFacetResult res = super.fetchPartitionResult(facetArrays, offset);
          if (countForbiddenDimension!=null) {
View Full Code Here

        }

        if (fr.getResultMode() == ResultMode.PER_NODE_IN_TREE) {
            return new TopKInEachNodeHandler(taxonomyReader, fr, facetArrays);
        }
        return new TopKFacetResultsHandler(taxonomyReader, fr, facetArrays);
    }
View Full Code Here

   
    @Override
    /** Override this method just for verifying that only specified facets are iterated.. */
    public FacetResultsHandler createFacetResultsHandler(
        TaxonomyReader taxonomyReader) {
      return new TopKFacetResultsHandler(taxonomyReader, this) {
        @Override
        public IntermediateFacetResult fetchPartitionResult(
            FacetArrays facetArrays, int offset) throws IOException {
          final IntermediateFacetResult res = super.fetchPartitionResult(facetArrays, offset);
          if (countForbiddenDimension!=null) {
View Full Code Here

TOP

Related Classes of org.apache.lucene.facet.search.TopKFacetResultsHandler

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.