Class CustomScoreQuery
Query that sets document score as a programmatic function of several (sub) scores:
WARNING: The status of the Search.Function package is experimental. The APIs introduced here might change in the future and will not be supported anymore in such a case.
Inherited Members
Namespace:
Assembly: Lucene.Net.NetCore.dll
Syntax
public class CustomScoreQuery : Query, ICloneable
Constructors
Name | Description |
---|---|
CustomScoreQuery(Query) | Create a CustomScoreQuery over input subQuery. |
CustomScoreQuery(Query, ValueSourceQuery) | Create a CustomScoreQuery over input subQuery and a ValueSourceQuery. |
CustomScoreQuery(Query, ValueSourceQuery[]) | Create a CustomScoreQuery over input subQuery and a ValueSourceQuery. |
Methods
Name | Description |
---|---|
Clone() | |
CreateWeight(Searcher) | |
CustomExplain(Int32, Explanation, Explanation) | Explain the custom score. The doc is relative to the current reader, which is unknown to CustomScoreQuery when using per-segment search (since Lucene 2.9). Please override GetCustomScoreProvider(IndexReader) and return a subclass of CustomScoreProvider for the given IndexReader. |
CustomExplain(Int32, Explanation, Explanation[]) | Explain the custom score. The doc is relative to the current reader, which is unknown to CustomScoreQuery when using per-segment search (since Lucene 2.9). Please override GetCustomScoreProvider(IndexReader) and return a subclass of CustomScoreProvider for the given IndexReader. |
CustomScore(Int32, Single, Single) | Compute a custom score by the subQuery score and the ValueSourceQuery score. The doc is relative to the current reader, which is unknown to CustomScoreQuery when using per-segment search (since Lucene 2.9). Please override GetCustomScoreProvider(IndexReader) and return a subclass of CustomScoreProvider for the given IndexReader. |
CustomScore(Int32, Single, Single[]) | Compute a custom score by the subQuery score and a number of ValueSourceQuery scores. The doc is relative to the current reader, which is unknown to CustomScoreQuery when using per-segment search (since Lucene 2.9). Please override GetCustomScoreProvider(IndexReader) and return a subclass of CustomScoreProvider for the given IndexReader. see CustomScoreProvider#customScore(int,float,float[]) |
Equals(Object) | Returns true if |
ExtractTerms(Collections.Generic.ISet<Term>) | |
GetCustomScoreProvider(IndexReader) | Returns a CustomScoreProvider that calculates the custom scores for the given IndexReader. The default implementation returns a default implementation as specified in the docs of CustomScoreProvider. |
GetHashCode() | Returns a hash code value for this object. |
IsStrict() | Checks if this is strict custom scoring.
In strict custom scoring, the ValueSource part does not participate in weight normalization.
This may be useful when one wants full control over how scores are modified, and does
not care about normalizing by the ValueSource part.
One particular case where this is useful if for testing this query. Note: only has effect when the ValueSource part is not null. |
Name() | A short name of this query, used in |
Rewrite(IndexReader) | |
SetStrict(Boolean) | Set the strict mode of this query. |
ToString(String) |