Constructor CustomScoreQuery
CustomScoreQuery(Query)
Create a CustomScoreQuery over input subQuery.
Declaration
public CustomScoreQuery(Query subQuery)
Parameters
Type | Name | Description |
---|---|---|
Query | subQuery | the sub query whose scored is being customed. Must not be null. |
CustomScoreQuery(Query, ValueSourceQuery)
Create a CustomScoreQuery over input subQuery and a ValueSourceQuery.
Declaration
public CustomScoreQuery(Query subQuery, ValueSourceQuery valSrcQuery)
Parameters
Type | Name | Description |
---|---|---|
Query | subQuery | the sub query whose score is being customed. Must not be null. |
ValueSourceQuery | valSrcQuery | a value source query whose scores are used in the custom score computation. For most simple/convineient use case this would be a FieldScoreQuery. This parameter is optional - it can be null or even an empty array. |
CustomScoreQuery(Query, ValueSourceQuery[])
Create a CustomScoreQuery over input subQuery and a ValueSourceQuery.
Declaration
public CustomScoreQuery(Query subQuery, params ValueSourceQuery[] valSrcQueries)
Parameters
Type | Name | Description |
---|---|---|
Query | subQuery | the sub query whose score is being customized. Must not be null. |
ValueSourceQuery[] | valSrcQueries | value source queries whose scores are used in the custom score computation. For most simple/convenient use case these would be FieldScoreQuery. This parameter is optional - it can be null or even an empty array. |