Package org.apache.accumulo.examples.wikisearch.parser

Examples of org.apache.accumulo.examples.wikisearch.parser.RangeCalculator$RangeBounds


 
  @Override
  protected RangeCalculator getTermIndexInformation(Connector c, Authorizations auths, Multimap<String,Normalizer> indexedTerms,
      Multimap<String,QueryTerm> terms, String indexTableName, String reverseIndexTableName, String queryString, int queryThreads, Set<String> typeFilter)
      throws TableNotFoundException, org.apache.commons.jexl2.parser.ParseException {
    RangeCalculator calc = new RangeCalculator();
    calc.execute(c, auths, indexedTerms, terms, queryString, this, typeFilter);
    return calc;
  }
View Full Code Here


            queryString = buf.toString();
          } else {
            throw new RuntimeException("Unexpected IndexRanges implementation");
          }
        } else {
          RangeCalculator calc = this.getTermIndexInformation(connector, auths, indexedTerms, terms, this.getIndexTableName(), this.getReverseIndexTableName(),
              queryString, this.queryThreads, typeFilter);
          if (null == calc.getResult() || calc.getResult().isEmpty()) {
            // Then we didn't find anything in the index for this query. This may happen for an indexed term that has wildcards
            // in unhandled locations.
            // Break out of here by throwing a named exception and do full scan
            throw new DoNotPerformOptimizedQueryException();
          }
          termIndexInfo = new UnionIndexRanges();
          termIndexInfo.setIndexValuesToOriginalValues(calc.getIndexValues());
          termIndexInfo.setFieldNamesAndValues(calc.getIndexEntries());
          termIndexInfo.getTermCardinality().putAll(calc.getTermCardinalities());
          for (Range r : calc.getResult()) {
            // foo is a placeholder and is ignored.
            termIndexInfo.add("foo", r);
          }
        }
      } catch (TableNotFoundException e) {
View Full Code Here

TOP

Related Classes of org.apache.accumulo.examples.wikisearch.parser.RangeCalculator$RangeBounds

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.