public class SearchModule extends AbstractModule
Modifier and Type | Field and Description |
---|---|
static Setting<java.lang.Integer> |
INDICES_MAX_CLAUSE_COUNT_SETTING |
Constructor and Description |
---|
SearchModule(Settings settings,
NamedWriteableRegistry namedWriteableRegistry) |
addError, addError, addError, bind, bind, bind, bindConstant, binder, bindListener, bindScope, configure, convertToTypes, currentStage, getMembersInjector, getMembersInjector, getProvider, getProvider, install, requestInjection, requestStaticInjection, requireBinding, requireBinding
public static final Setting<java.lang.Integer> INDICES_MAX_CLAUSE_COUNT_SETTING
public SearchModule(Settings settings, NamedWriteableRegistry namedWriteableRegistry)
public void registerHighlighter(java.lang.String key, Highlighter highligher)
public void registerSuggester(java.lang.String key, Suggester<?> suggester)
public <T extends ScoreFunctionBuilder<T>> void registerScoreFunction(Writeable.Reader<T> reader, ScoreFunctionParser<T> parser, ParseField functionName)
ScoreFunctionParser
which parses XContent into a ScoreFunctionBuilder
using its ParseField
Writeable.Reader
which reads a stream representation of the builder under the
ParseField.getPreferredName().public <QB extends QueryBuilder> void registerQuery(Writeable.Reader<QB> reader, QueryParser<QB> queryParser, ParseField queryName)
reader
- the reader registered for this query's builder. Typically a reference to a constructor that takes a
StreamInput
queryParser
- the parser the reads the query builder from xcontentqueryName
- holds the names by which this query might be parsed. The ParseField.getPreferredName()
is special as it
is the name by under which the reader is registered. So it is the name that the query should use as its
NamedWriteable.getWriteableName()
too.public IndicesQueriesRegistry getQueryParserRegistry()
public void registerFetchSubPhase(FetchSubPhase subPhase)
FetchSubPhase
instance. This sub phase is executed when docuemnts are fetched for instanced to highlight
documents.public Highlighters getHighlighters()
Highlighter
registrypublic void registerSignificanceHeuristic(ParseField heuristicName, Writeable.Reader<SignificanceHeuristic> reader, SignificanceHeuristicParser parser)
SignificanceHeuristic
.heuristicName
- the name(s) at which the heuristic is parsed and streamed. The ParseField.getPreferredName()
is the name
under which it is streamed. All names work for the parser.reader
- reads the heuristic from a streamparser
- reads the heuristic from an XContentParserpublic ParseFieldRegistry<SignificanceHeuristicParser> getSignificanceHeuristicParserRegistry()
SignificanceHeuristic
s.public void registerMovingAverageModel(ParseField modelName, Writeable.Reader<MovAvgModel> reader, MovAvgModel.AbstractModelParser parser)
MovAvgModel
.modelName
- the name(s) at which the model is parsed and streamed. The ParseField.getPreferredName()
is the name under
which it is streamed. All named work for the parser.reader
- reads the model from a streamparser
- reads the model from an XContentParserpublic ParseFieldRegistry<MovAvgModel.AbstractModelParser> getMovingAverageMdelParserRegistry()
MovAvgModel
s.public void registerAggregation(Writeable.Reader<? extends AggregationBuilder> reader, Aggregator.Parser aggregationParser, ParseField aggregationName)
reader
- reads the aggregation builder from a streamaggregationParser
- reads the aggregation builder from XContentaggregationName
- names by which the aggregation may be parsed. The first name is special because it is the name that the reader
is registered under.public void registerPipelineAggregation(Writeable.Reader<? extends PipelineAggregationBuilder> reader, PipelineAggregator.Parser aggregationParser, ParseField aggregationName)
reader
- reads the aggregation builder from a streamaggregationParser
- reads the aggregation builder from XContentaggregationName
- names by which the aggregation may be parsed. The first name is special because it is the name that the reader
is registered under.protected void configure()
AbstractModule
Binder
via the exposed methods.configure
in class AbstractModule
protected void configureAggs()
protected void configureSearch()
public Suggesters getSuggesters()