public class MissingParser extends AbstractValuesSourceParser.AnyValuesSourceParser
AbstractValuesSourceParser.AnyValuesSourceParser, AbstractValuesSourceParser.BytesValuesSourceParser, AbstractValuesSourceParser.GeoPointValuesSourceParser, AbstractValuesSourceParser.NumericValuesSourceParser
Constructor and Description |
---|
MissingParser() |
Modifier and Type | Method and Description |
---|---|
protected MissingAggregationBuilder |
createFactory(java.lang.String aggregationName,
ValuesSourceType valuesSourceType,
ValueType targetValueType,
java.util.Map<ParseField,java.lang.Object> otherOptions)
Creates a
ValuesSourceAggregationBuilder from the information
gathered by the subclass. |
protected boolean |
token(java.lang.String aggregationName,
java.lang.String currentFieldName,
XContentParser.Token token,
XContentParseContext context,
java.util.Map<ParseField,java.lang.Object> otherOptions)
Allows subclasses of
AbstractValuesSourceParser to parse extra
parameters and store them in a Map which will later be passed to
AbstractValuesSourceParser.createFactory(String, ValuesSourceType, ValueType, Map) . |
parse
protected boolean token(java.lang.String aggregationName, java.lang.String currentFieldName, XContentParser.Token token, XContentParseContext context, java.util.Map<ParseField,java.lang.Object> otherOptions) throws java.io.IOException
AbstractValuesSourceParser
AbstractValuesSourceParser
to parse extra
parameters and store them in a Map
which will later be passed to
AbstractValuesSourceParser.createFactory(String, ValuesSourceType, ValueType, Map)
.token
in class AbstractValuesSourceParser<ValuesSource>
aggregationName
- the name of the aggregationcurrentFieldName
- the name of the current field being parsedtoken
- the current token for the parsercontext
- the query contextotherOptions
- a Map
of options to be populated by successive calls
to this method which will then be passed to the
AbstractValuesSourceParser.createFactory(String, ValuesSourceType, ValueType, Map)
methodtrue
if the current token was correctly parsed,
false
otherwisejava.io.IOException
- if an error occurs whilst parsingprotected MissingAggregationBuilder createFactory(java.lang.String aggregationName, ValuesSourceType valuesSourceType, ValueType targetValueType, java.util.Map<ParseField,java.lang.Object> otherOptions)
AbstractValuesSourceParser
ValuesSourceAggregationBuilder
from the information
gathered by the subclass. Options parsed in
AbstractValuesSourceParser
itself will be added to the factory
after it has been returned by this method.createFactory
in class AbstractValuesSourceParser<ValuesSource>
aggregationName
- the name of the aggregationvaluesSourceType
- the type of the ValuesSource
targetValueType
- the target type of the final value output by the aggregationotherOptions
- a Map
containing the extra options parsed by the
AbstractValuesSourceParser.token(String, String, XContentParser.Token, XContentParseContext, Map)
method