public class BoostFieldMapper extends NumberFieldMapper<Float> implements InternalMapper, RootMapper
Modifier and Type | Class and Description |
---|---|
static class |
BoostFieldMapper.Builder |
static class |
BoostFieldMapper.Defaults |
static class |
BoostFieldMapper.TypeParser |
NumberFieldMapper.CustomLongNumericDocValuesField, NumberFieldMapper.CustomNumericDocValuesField, NumberFieldMapper.CustomNumericField
AbstractFieldMapper.CopyTo, AbstractFieldMapper.MultiFields
Mapper.BuilderContext
ToXContent.DelegatingMapParams, ToXContent.MapParams, ToXContent.Params
FieldMapper.Loading, FieldMapper.Names
Modifier and Type | Field and Description |
---|---|
static String |
CONTENT_TYPE |
static String |
NAME |
coerce, ignoreMalformed, includeInAll, precisionStep, useSortedNumericDocValues
boost, copyTo, customFieldDataSettings, docValues, docValuesFormat, fieldDataType, fieldType, indexAnalyzer, multiFields, names, normsLoading, postingsFormat, searchAnalyzer, similarity
EMPTY_ARRAY
EMPTY_PARAMS
DOC_VALUES_FORMAT
Modifier | Constructor and Description |
---|---|
|
BoostFieldMapper(Settings indexSettings) |
protected |
BoostFieldMapper(String name,
String indexName,
int precisionStep,
float boost,
org.apache.lucene.document.FieldType fieldType,
Boolean docValues,
Float nullValue,
PostingsFormatProvider postingsProvider,
DocValuesFormatProvider docValuesProvider,
Settings fieldDataSettings,
Settings indexSettings) |
protected |
BoostFieldMapper(String name,
String indexName,
Settings indexSettings) |
Modifier and Type | Method and Description |
---|---|
protected String |
contentType() |
FieldDataType |
defaultFieldDataType() |
org.apache.lucene.document.FieldType |
defaultFieldType() |
org.apache.lucene.search.Query |
fuzzyQuery(String value,
Fuzziness fuzziness,
int prefixLength,
int maxExpansions,
boolean transpositions) |
boolean |
hasDocValues() |
boolean |
includeInObject()
Should the mapper be included in the root
ObjectMapper . |
org.apache.lucene.util.BytesRef |
indexedValueForSearch(Object value)
Returns the indexed value used to construct search "values".
|
protected void |
innerParseCreateField(ParseContext context,
List<org.apache.lucene.document.Field> fields) |
protected int |
maxPrecisionStep() |
void |
merge(Mapper mergeWith,
MergeContext mergeContext) |
org.apache.lucene.search.Filter |
nullValueFilter()
Null value filter, returns null if there is no null value associated with the field.
|
void |
parse(ParseContext context) |
void |
postParse(ParseContext context)
Called after
Mapper.parse(ParseContext) on the RootObjectMapper . |
void |
preParse(ParseContext context)
Called before
Mapper.parse(ParseContext) on the RootObjectMapper . |
org.apache.lucene.search.Filter |
rangeFilter(Object lowerTerm,
Object upperTerm,
boolean includeLower,
boolean includeUpper,
QueryParseContext context) |
org.apache.lucene.search.Filter |
rangeFilter(QueryParseContext parseContext,
Object lowerTerm,
Object upperTerm,
boolean includeLower,
boolean includeUpper,
QueryParseContext context)
A range filter based on the field data cache.
|
org.apache.lucene.search.Query |
rangeQuery(Object lowerTerm,
Object upperTerm,
boolean includeLower,
boolean includeUpper,
QueryParseContext context) |
XContentBuilder |
toXContent(XContentBuilder builder,
ToXContent.Params params) |
Float |
value(Object value)
Returns the actual value of the field.
|
addDocValue, close, doXContentBody, fieldDataTermsFilter, includeInAll, includeInAllIfNotSet, isNumeric, parseCreateField, parseDoubleValue, parseLongValue, popCachedStream, precisionStep, termFilter, termQuery, unsetIncludeInAll, useTermQueryWithQueryString, valueForSearch
boost, copyTo, customBoost, defaultDocValuesFormat, defaultPostingFormat, docValuesFormatProvider, fieldDataType, fieldType, indexAnalyzer, indexOptionToString, indexTokenizeOptionToString, isGenerated, isSortable, name, names, normsLoading, postingsFormatProvider, prefixFilter, prefixQuery, queryStringTermQuery, regexpFilter, regexpQuery, searchAnalyzer, searchQuoteAnalyzer, similarity, supportsNullValue, termsFilter, termVectorOptionsToString, traverse, traverse
public static final String CONTENT_TYPE
public static final String NAME
public BoostFieldMapper(Settings indexSettings)
protected BoostFieldMapper(String name, String indexName, int precisionStep, float boost, org.apache.lucene.document.FieldType fieldType, Boolean docValues, Float nullValue, PostingsFormatProvider postingsProvider, DocValuesFormatProvider docValuesProvider, @Nullable Settings fieldDataSettings, Settings indexSettings)
public org.apache.lucene.document.FieldType defaultFieldType()
defaultFieldType
in class AbstractFieldMapper<Float>
public FieldDataType defaultFieldDataType()
defaultFieldDataType
in class AbstractFieldMapper<Float>
public boolean hasDocValues()
hasDocValues
in interface FieldMapper<Float>
hasDocValues
in class AbstractFieldMapper<Float>
protected int maxPrecisionStep()
maxPrecisionStep
in class NumberFieldMapper<Float>
public Float value(Object value)
FieldMapper
value
in interface FieldMapper<Float>
public org.apache.lucene.util.BytesRef indexedValueForSearch(Object value)
FieldMapper
indexedValueForSearch
in interface FieldMapper<Float>
indexedValueForSearch
in class AbstractFieldMapper<Float>
public org.apache.lucene.search.Query fuzzyQuery(String value, Fuzziness fuzziness, int prefixLength, int maxExpansions, boolean transpositions)
fuzzyQuery
in interface FieldMapper<Float>
fuzzyQuery
in class NumberFieldMapper<Float>
public org.apache.lucene.search.Query rangeQuery(Object lowerTerm, Object upperTerm, boolean includeLower, boolean includeUpper, @Nullable QueryParseContext context)
rangeQuery
in interface FieldMapper<Float>
rangeQuery
in class NumberFieldMapper<Float>
public org.apache.lucene.search.Filter rangeFilter(Object lowerTerm, Object upperTerm, boolean includeLower, boolean includeUpper, @Nullable QueryParseContext context)
rangeFilter
in interface FieldMapper<Float>
rangeFilter
in class NumberFieldMapper<Float>
public org.apache.lucene.search.Filter rangeFilter(QueryParseContext parseContext, Object lowerTerm, Object upperTerm, boolean includeLower, boolean includeUpper, @Nullable QueryParseContext context)
NumberFieldMapper
rangeFilter
in class NumberFieldMapper<Float>
public org.apache.lucene.search.Filter nullValueFilter()
FieldMapper
nullValueFilter
in interface FieldMapper<Float>
nullValueFilter
in class AbstractFieldMapper<Float>
public void preParse(ParseContext context) throws IOException
RootMapper
Mapper.parse(ParseContext)
on the RootObjectMapper
.preParse
in interface RootMapper
IOException
public void postParse(ParseContext context) throws IOException
RootMapper
Mapper.parse(ParseContext)
on the RootObjectMapper
.postParse
in interface RootMapper
IOException
public boolean includeInObject()
RootMapper
ObjectMapper
.
If this method returns true, then Mapper.parse(ParseContext)
will be
called if the context has a property that matches the name of this
RootMapper
. Otherwise Mapper.parse(ParseContext)
will not
be called.includeInObject
in interface RootMapper
public void parse(ParseContext context) throws IOException
parse
in interface Mapper
parse
in class AbstractFieldMapper<Float>
IOException
protected void innerParseCreateField(ParseContext context, List<org.apache.lucene.document.Field> fields) throws IOException
innerParseCreateField
in class NumberFieldMapper<Float>
IOException
protected String contentType()
contentType
in class AbstractFieldMapper<Float>
public XContentBuilder toXContent(XContentBuilder builder, ToXContent.Params params) throws IOException
toXContent
in interface ToXContent
toXContent
in class AbstractFieldMapper<Float>
IOException
public void merge(Mapper mergeWith, MergeContext mergeContext) throws MergeMappingException
merge
in interface Mapper
merge
in class NumberFieldMapper<Float>
MergeMappingException
Copyright © 2009–2015. All rights reserved.