org.elasticsearch.index.query
Class CustomBoostFactorQueryBuilder

java.lang.Object
  extended by org.elasticsearch.index.query.BaseQueryBuilder
      extended by org.elasticsearch.index.query.CustomBoostFactorQueryBuilder
All Implemented Interfaces:
ToXContent, QueryBuilder

public class CustomBoostFactorQueryBuilder
extends BaseQueryBuilder

A query that simply applies the boost factor to another query (multiply it).


Nested Class Summary
 
Nested classes/interfaces inherited from interface org.elasticsearch.common.xcontent.ToXContent
ToXContent.MapParams, ToXContent.Params
 
Field Summary
 
Fields inherited from interface org.elasticsearch.common.xcontent.ToXContent
EMPTY_PARAMS
 
Constructor Summary
CustomBoostFactorQueryBuilder(QueryBuilder queryBuilder)
          A query that simply applies the boost factor to another query (multiply it).
 
Method Summary
 CustomBoostFactorQueryBuilder boostFactor(float boost)
          Sets the boost factor for this query.
protected  void doXContent(XContentBuilder builder, ToXContent.Params params)
           
 
Methods inherited from class org.elasticsearch.index.query.BaseQueryBuilder
buildAsBytes, buildAsBytes, toString, toXContent
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

CustomBoostFactorQueryBuilder

public CustomBoostFactorQueryBuilder(QueryBuilder queryBuilder)
A query that simply applies the boost factor to another query (multiply it).

Parameters:
queryBuilder - The query to apply the boost factor to.
Method Detail

boostFactor

public CustomBoostFactorQueryBuilder boostFactor(float boost)
Sets the boost factor for this query.


doXContent

protected void doXContent(XContentBuilder builder,
                          ToXContent.Params params)
                   throws IOException
Specified by:
doXContent in class BaseQueryBuilder
Throws:
IOException


Copyright © 2009-2012. All Rights Reserved.