final class MultiNormsLeafSimScorer
extends java.lang.Object
LeafSimScorer that sums document's norms from multiple fields.| Modifier and Type | Class and Description |
|---|---|
private static class |
MultiNormsLeafSimScorer.MultiFieldNormValues |
| Modifier and Type | Field and Description |
|---|---|
private static float[] |
LENGTH_TABLE
Cache of decoded norms.
|
private NumericDocValues |
norms |
private Similarity.SimScorer |
scorer |
| Constructor and Description |
|---|
MultiNormsLeafSimScorer(Similarity.SimScorer scorer,
LeafReader reader,
java.util.Collection<BM25FQuery.FieldAndWeight> normFields,
boolean needsScores)
Sole constructor: Score documents of
reader with scorer. |
| Modifier and Type | Method and Description |
|---|---|
Explanation |
explain(int doc,
Explanation freqExpl)
Explain the score for the provided document assuming the given term document frequency.
|
private long |
getNormValue(int doc) |
float |
score(int doc,
float freq)
Score the provided document assuming the given term document frequency.
|
private static final float[] LENGTH_TABLE
private final Similarity.SimScorer scorer
private final NumericDocValues norms
MultiNormsLeafSimScorer(Similarity.SimScorer scorer, LeafReader reader, java.util.Collection<BM25FQuery.FieldAndWeight> normFields, boolean needsScores) throws java.io.IOException
reader with scorer.java.io.IOExceptionprivate long getNormValue(int doc)
throws java.io.IOException
java.io.IOExceptionpublic float score(int doc,
float freq)
throws java.io.IOException
java.io.IOExceptionSimilarity.SimScorer.score(float, long)public Explanation explain(int doc, Explanation freqExpl) throws java.io.IOException
java.io.IOExceptionSimilarity.SimScorer.explain(Explanation, long)