org.elasticsearch.index.query
Class FuzzyLikeThisQueryBuilder
java.lang.Object
org.elasticsearch.index.query.BaseQueryBuilder
org.elasticsearch.index.query.FuzzyLikeThisQueryBuilder
- All Implemented Interfaces:
- ToXContent, QueryBuilder
public class FuzzyLikeThisQueryBuilder
- extends BaseQueryBuilder
Constructor Summary |
FuzzyLikeThisQueryBuilder()
Constructs a new fuzzy like this query which uses the "_all" field. |
FuzzyLikeThisQueryBuilder(java.lang.String... fields)
Sets the field names that will be used when generating the 'Fuzzy Like This' query. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
FuzzyLikeThisQueryBuilder
public FuzzyLikeThisQueryBuilder()
- Constructs a new fuzzy like this query which uses the "_all" field.
FuzzyLikeThisQueryBuilder
public FuzzyLikeThisQueryBuilder(java.lang.String... fields)
- Sets the field names that will be used when generating the 'Fuzzy Like This' query.
- Parameters:
fields
- the field names that will be used when generating the 'Fuzzy Like This' query.
likeText
public FuzzyLikeThisQueryBuilder likeText(java.lang.String likeText)
- The text to use in order to find documents that are "like" this.
minSimilarity
public FuzzyLikeThisQueryBuilder minSimilarity(float minSimilarity)
prefixLength
public FuzzyLikeThisQueryBuilder prefixLength(int prefixLength)
maxQueryTerms
public FuzzyLikeThisQueryBuilder maxQueryTerms(int maxQueryTerms)
ignoreTF
public FuzzyLikeThisQueryBuilder ignoreTF(boolean ignoreTF)
analyzer
public FuzzyLikeThisQueryBuilder analyzer(java.lang.String analyzer)
- The analyzer that will be used to analyze the text. Defaults to the analyzer associated with the fied.
boost
public FuzzyLikeThisQueryBuilder boost(float boost)
doXContent
protected void doXContent(XContentBuilder builder,
ToXContent.Params params)
throws java.io.IOException
- Specified by:
doXContent
in class BaseQueryBuilder
- Throws:
java.io.IOException