public class FuzzyLikeThisQuery extends Query
Constructor and Description |
---|
FuzzyLikeThisQuery(int maxNumTerms,
Analyzer analyzer) |
Modifier and Type | Method and Description |
---|---|
void |
addTerms(String queryString,
String fieldName,
float minSimilarity,
int prefixLength)
Adds user input for "fuzzification"
|
boolean |
equals(Object other) |
int |
hashCode() |
boolean |
isIgnoreTF() |
Query |
rewrite(IndexReader reader) |
void |
setIgnoreTF(boolean ignoreTF) |
String |
toString(String field) |
void |
visit(QueryVisitor visitor) |
classHash, createWeight, sameClassAs, toString
public FuzzyLikeThisQuery(int maxNumTerms, Analyzer analyzer)
maxNumTerms
- The total number of terms clauses that will appear once rewritten as a BooleanQuerypublic void addTerms(String queryString, String fieldName, float minSimilarity, int prefixLength)
queryString
- The string which will be parsed by the analyzer and for which fuzzy variants will be parsedminSimilarity
- The minimum similarity of the term variants; must be 0, 1 or 2 (see FuzzyTermsEnum)prefixLength
- Length of required common prefix on variant terms (see FuzzyTermsEnum)public void visit(QueryVisitor visitor)
public Query rewrite(IndexReader reader) throws IOException
rewrite
in class Query
IOException
public boolean isIgnoreTF()
public void setIgnoreTF(boolean ignoreTF)
Copyright © 2000-2019 Apache Software Foundation. All Rights Reserved.