org.elasticsearch.index.query
Class CustomFiltersScoreQueryBuilder
java.lang.Object
org.elasticsearch.index.query.BaseQueryBuilder
org.elasticsearch.index.query.CustomFiltersScoreQueryBuilder
- All Implemented Interfaces:
- ToXContent, QueryBuilder
public class CustomFiltersScoreQueryBuilder
- extends BaseQueryBuilder
A query that uses a filters with a script associated with them to compute the score.
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
CustomFiltersScoreQueryBuilder
public CustomFiltersScoreQueryBuilder(QueryBuilder queryBuilder)
add
public CustomFiltersScoreQueryBuilder add(FilterBuilder filter,
java.lang.String script)
add
public CustomFiltersScoreQueryBuilder add(FilterBuilder filter,
float boost)
scoreMode
public CustomFiltersScoreQueryBuilder scoreMode(java.lang.String scoreMode)
lang
public CustomFiltersScoreQueryBuilder lang(java.lang.String lang)
- Sets the language of the script.
params
public CustomFiltersScoreQueryBuilder params(java.util.Map<java.lang.String,java.lang.Object> params)
- Additional parameters that can be provided to the script.
param
public CustomFiltersScoreQueryBuilder param(java.lang.String key,
java.lang.Object value)
- Additional parameters that can be provided to the script.
boost
public CustomFiltersScoreQueryBuilder boost(float boost)
- Sets the boost for this query. Documents matching this query will (in addition to the normal
weightings) have their score multiplied by the boost provided.
doXContent
protected void doXContent(XContentBuilder builder,
ToXContent.Params params)
throws java.io.IOException
- Specified by:
doXContent
in class BaseQueryBuilder
- Throws:
java.io.IOException