Class ScoreFunction
java.lang.Object
org.elasticsearch.common.lucene.search.function.ScoreFunction
- Direct Known Subclasses:
DecayFunctionBuilder.AbstractDistanceScoreFunction,FieldValueFactorFunction,FunctionScoreQuery.FilterScoreFunction,RandomScoreFunction,ScriptScoreFunction,WeightFactorFunction
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected abstract booleandoEquals(ScoreFunction other)Indicates whether some otherScoreFunctionobject of the same type is "equal to" this one.protected abstract intbooleanabstract LeafScoreFunctiongetLeafScoreFunction(org.apache.lucene.index.LeafReaderContext ctx)floatinthashCode()abstract booleanIndicates if document scores are needed by this function.protected ScoreFunctionrewrite(org.apache.lucene.index.IndexReader reader)
-
Constructor Details
-
ScoreFunction
-
-
Method Details
-
getDefaultScoreCombiner
-
getLeafScoreFunction
public abstract LeafScoreFunction getLeafScoreFunction(org.apache.lucene.index.LeafReaderContext ctx) throws IOException- Throws:
IOException
-
needsScores
public abstract boolean needsScores()Indicates if document scores are needed by this function.- Returns:
trueif scores are needed.
-
equals
-
getWeight
public float getWeight() -
doEquals
Indicates whether some otherScoreFunctionobject of the same type is "equal to" this one. -
hashCode
public final int hashCode() -
doHashCode
protected abstract int doHashCode() -
rewrite
- Throws:
IOException
-