Java Code Examples for org.apache.lucene.search.MultiTermQuery#setRewriteMethod()

The following examples show how to use org.apache.lucene.search.MultiTermQuery#setRewriteMethod() . You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: QueryParsers.java    From Elasticsearch with Apache License 2.0 4 votes vote down vote up
public static void setRewriteMethod(MultiTermQuery query, @Nullable MultiTermQuery.RewriteMethod rewriteMethod) {
    if (rewriteMethod == null) {
        return;
    }
    query.setRewriteMethod(rewriteMethod);
}
 
Example 2
Source File: QueryParsers.java    From Elasticsearch with Apache License 2.0 4 votes vote down vote up
public static void setRewriteMethod(MultiTermQuery query, ParseFieldMatcher matcher, @Nullable String rewriteMethod) {
    if (rewriteMethod == null) {
        return;
    }
    query.setRewriteMethod(parseRewriteMethod(matcher, rewriteMethod));
}
 
Example 3
Source File: QueryParsers.java    From crate with Apache License 2.0 4 votes vote down vote up
public static void setRewriteMethod(MultiTermQuery query, @Nullable MultiTermQuery.RewriteMethod rewriteMethod) {
    if (rewriteMethod == null) {
        return;
    }
    query.setRewriteMethod(rewriteMethod);
}