Class ExponentialDecayFunctionBuilder
java.lang.Object
org.elasticsearch.index.query.functionscore.ScoreFunctionBuilder<DFB>
org.elasticsearch.index.query.functionscore.DecayFunctionBuilder<ExponentialDecayFunctionBuilder>
org.elasticsearch.index.query.functionscore.ExponentialDecayFunctionBuilder
- All Implemented Interfaces:
NamedWriteable,Writeable,org.elasticsearch.common.xcontent.ToXContent,org.elasticsearch.common.xcontent.ToXContentFragment
public class ExponentialDecayFunctionBuilder extends DecayFunctionBuilder<ExponentialDecayFunctionBuilder>
-
Nested Class Summary
Nested classes/interfaces inherited from class org.elasticsearch.index.query.functionscore.DecayFunctionBuilder
DecayFunctionBuilder.AbstractDistanceScoreFunctionNested classes/interfaces inherited from interface org.elasticsearch.common.xcontent.ToXContent
org.elasticsearch.common.xcontent.ToXContent.DelegatingMapParams, org.elasticsearch.common.xcontent.ToXContent.MapParams, org.elasticsearch.common.xcontent.ToXContent.ParamsNested classes/interfaces inherited from interface org.elasticsearch.common.io.stream.Writeable
Writeable.Reader<V>, Writeable.Writer<V> -
Field Summary
Fields Modifier and Type Field Description static DecayFunctionEXP_DECAY_FUNCTIONstatic java.lang.StringNAMEstatic ScoreFunctionParser<ExponentialDecayFunctionBuilder>PARSERFields inherited from class org.elasticsearch.index.query.functionscore.DecayFunctionBuilder
DECAY, DEFAULT_DECAY, DEFAULT_MULTI_VALUE_MODE, OFFSET, ORIGIN, SCALE -
Constructor Summary
Constructors Constructor Description ExponentialDecayFunctionBuilder(java.lang.String fieldName, java.lang.Object origin, java.lang.Object scale, java.lang.Object offset)ExponentialDecayFunctionBuilder(java.lang.String fieldName, java.lang.Object origin, java.lang.Object scale, java.lang.Object offset, double decay)ExponentialDecayFunctionBuilder(StreamInput in)Read from a stream. -
Method Summary
Modifier and Type Method Description DecayFunctiongetDecayFunction()Override this function if you want to produce your own scorer.java.lang.StringgetName()The name of this score function.Methods inherited from class org.elasticsearch.index.query.functionscore.DecayFunctionBuilder
doEquals, doHashCode, doToFunction, doWriteTo, doXContent, getFieldName, getFunctionBytes, getMultiValueMode, setMultiValueModeMethods inherited from class org.elasticsearch.index.query.functionscore.ScoreFunctionBuilder
equals, getWeight, getWriteableName, hashCode, setWeight, toFunction, toXContent, writeTo
-
Field Details
-
NAME
public static final java.lang.String NAME- See Also:
- Constant Field Values
-
PARSER
-
EXP_DECAY_FUNCTION
-
-
Constructor Details
-
ExponentialDecayFunctionBuilder
public ExponentialDecayFunctionBuilder(java.lang.String fieldName, java.lang.Object origin, java.lang.Object scale, java.lang.Object offset) -
ExponentialDecayFunctionBuilder
public ExponentialDecayFunctionBuilder(java.lang.String fieldName, java.lang.Object origin, java.lang.Object scale, java.lang.Object offset, double decay) -
ExponentialDecayFunctionBuilder
Read from a stream.- Throws:
java.io.IOException
-
-
Method Details
-
getName
public java.lang.String getName()Description copied from class:ScoreFunctionBuilderThe name of this score function.- Specified by:
getNamein classScoreFunctionBuilder<ExponentialDecayFunctionBuilder>
-
getDecayFunction
Description copied from class:DecayFunctionBuilderOverride this function if you want to produce your own scorer.- Specified by:
getDecayFunctionin classDecayFunctionBuilder<ExponentialDecayFunctionBuilder>
-