Package org.elasticsearch.search.rescore
Class RescorerBuilder<RB extends RescorerBuilder<RB>>
java.lang.Object
org.elasticsearch.search.rescore.RescorerBuilder<RB>
- All Implemented Interfaces:
NamedWriteable
,Writeable
,org.elasticsearch.common.xcontent.ToXContent
,org.elasticsearch.common.xcontent.ToXContentObject
,Rewriteable<RescorerBuilder<RB>>
- Direct Known Subclasses:
QueryRescorerBuilder
public abstract class RescorerBuilder<RB extends RescorerBuilder<RB>>
extends Object
implements NamedWriteable, org.elasticsearch.common.xcontent.ToXContentObject, Rewriteable<RescorerBuilder<RB>>
The abstract base builder for instances of
RescorerBuilder
.-
Nested Class Summary
Nested 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.Params
Nested classes/interfaces inherited from interface org.elasticsearch.common.io.stream.Writeable
Writeable.Reader<V>, Writeable.Writer<V>
-
Field Summary
Fields inherited from interface org.elasticsearch.index.query.Rewriteable
MAX_REWRITE_ROUNDS
Fields inherited from interface org.elasticsearch.common.xcontent.ToXContent
EMPTY_PARAMS
-
Constructor Summary
ModifierConstructorDescriptionConstruct an empty RescoreBuilder.protected
Read from a stream. -
Method Summary
Modifier and TypeMethodDescriptionbuildContext(SearchExecutionContext context)
Build the RescoreContext that will be used to actually execute the rescore against a particular shard.protected abstract void
doWriteTo(StreamOutput out)
protected abstract void
doXContent(org.elasticsearch.common.xcontent.XContentBuilder builder, org.elasticsearch.common.xcontent.ToXContent.Params params)
boolean
int
hashCode()
protected abstract RescoreContext
innerBuildContext(int windowSize, SearchExecutionContext context)
Extensions override this to build the context that they need for rescoring.static RescorerBuilder<?>
parseFromXContent(org.elasticsearch.common.xcontent.XContentParser parser)
toString()
org.elasticsearch.common.xcontent.XContentBuilder
toXContent(org.elasticsearch.common.xcontent.XContentBuilder builder, org.elasticsearch.common.xcontent.ToXContent.Params params)
windowSize(int windowSize)
void
writeTo(StreamOutput out)
Write this into the StreamOutput.Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface org.elasticsearch.common.io.stream.NamedWriteable
getWriteableName
Methods inherited from interface org.elasticsearch.index.query.Rewriteable
rewrite
Methods inherited from interface org.elasticsearch.common.xcontent.ToXContentObject
isFragment
-
Field Details
-
DEFAULT_WINDOW_SIZE
public static final int DEFAULT_WINDOW_SIZE- See Also:
- Constant Field Values
-
windowSize
-
-
Constructor Details
-
RescorerBuilder
public RescorerBuilder()Construct an empty RescoreBuilder. -
RescorerBuilder
Read from a stream.- Throws:
IOException
-
-
Method Details
-
writeTo
Description copied from interface:Writeable
Write this into the StreamOutput.- Specified by:
writeTo
in interfaceWriteable
- Throws:
IOException
-
doWriteTo
- Throws:
IOException
-
windowSize
-
windowSize
-
parseFromXContent
public static RescorerBuilder<?> parseFromXContent(org.elasticsearch.common.xcontent.XContentParser parser) throws IOException- Throws:
IOException
-
toXContent
public org.elasticsearch.common.xcontent.XContentBuilder toXContent(org.elasticsearch.common.xcontent.XContentBuilder builder, org.elasticsearch.common.xcontent.ToXContent.Params params) throws IOException- Specified by:
toXContent
in interfaceorg.elasticsearch.common.xcontent.ToXContent
- Throws:
IOException
-
doXContent
protected abstract void doXContent(org.elasticsearch.common.xcontent.XContentBuilder builder, org.elasticsearch.common.xcontent.ToXContent.Params params) throws IOException- Throws:
IOException
-
buildContext
Build the RescoreContext that will be used to actually execute the rescore against a particular shard.- Throws:
IOException
-
innerBuildContext
protected abstract RescoreContext innerBuildContext(int windowSize, SearchExecutionContext context) throws IOExceptionExtensions override this to build the context that they need for rescoring.- Throws:
IOException
-
hashCode
public int hashCode() -
equals
-
toString
-