org.elasticsearch.index.mapper.core
Class StringFieldMapper
java.lang.Object
org.elasticsearch.index.mapper.core.AbstractFieldMapper<String>
org.elasticsearch.index.mapper.core.StringFieldMapper
- All Implemented Interfaces:
- ToXContent, FieldMapper<String>, AllFieldMapper.IncludeInAll, Mapper
- Direct Known Subclasses:
- GeoPointFieldMapper.GeoStringFieldMapper
public class StringFieldMapper
- extends AbstractFieldMapper<String>
- implements AllFieldMapper.IncludeInAll
Constructor Summary |
protected |
StringFieldMapper(FieldMapper.Names names,
org.apache.lucene.document.Field.Index index,
org.apache.lucene.document.Field.Store store,
org.apache.lucene.document.Field.TermVector termVector,
float boost,
boolean omitNorms,
org.apache.lucene.index.FieldInfo.IndexOptions indexOptions,
String nullValue,
NamedAnalyzer indexAnalyzer,
NamedAnalyzer searchAnalyzer)
|
protected |
StringFieldMapper(FieldMapper.Names names,
org.apache.lucene.document.Field.Index index,
org.apache.lucene.document.Field.Store store,
org.apache.lucene.document.Field.TermVector termVector,
float boost,
boolean omitNorms,
org.apache.lucene.index.FieldInfo.IndexOptions indexOptions,
String nullValue,
NamedAnalyzer indexAnalyzer,
NamedAnalyzer searchAnalyzer,
NamedAnalyzer searchQuotedAnalyzer,
int positionOffsetGap,
int ignoreAbove)
|
Methods inherited from class org.elasticsearch.index.mapper.core.AbstractFieldMapper |
analyzed, boost, close, fieldDataType, fieldFilter, fieldQuery, fuzzyQuery, fuzzyQuery, index, indexAnalyzer, indexed, indexOptions, indexOptionToString, name, names, omitNorms, parse, prefixFilter, prefixQuery, queryStringTermQuery, rangeFilter, rangeQuery, searchAnalyzer, store, stored, termVector, toXContent, traverse, traverse, useFieldQueryWithQueryString, valueForSearch |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
CONTENT_TYPE
public static final String CONTENT_TYPE
- See Also:
- Constant Field Values
StringFieldMapper
protected StringFieldMapper(FieldMapper.Names names,
org.apache.lucene.document.Field.Index index,
org.apache.lucene.document.Field.Store store,
org.apache.lucene.document.Field.TermVector termVector,
float boost,
boolean omitNorms,
org.apache.lucene.index.FieldInfo.IndexOptions indexOptions,
String nullValue,
NamedAnalyzer indexAnalyzer,
NamedAnalyzer searchAnalyzer)
StringFieldMapper
protected StringFieldMapper(FieldMapper.Names names,
org.apache.lucene.document.Field.Index index,
org.apache.lucene.document.Field.Store store,
org.apache.lucene.document.Field.TermVector termVector,
float boost,
boolean omitNorms,
org.apache.lucene.index.FieldInfo.IndexOptions indexOptions,
String nullValue,
NamedAnalyzer indexAnalyzer,
NamedAnalyzer searchAnalyzer,
NamedAnalyzer searchQuotedAnalyzer,
int positionOffsetGap,
int ignoreAbove)
includeInAll
public void includeInAll(Boolean includeInAll)
- Specified by:
includeInAll
in interface AllFieldMapper.IncludeInAll
includeInAllIfNotSet
public void includeInAllIfNotSet(Boolean includeInAll)
- Specified by:
includeInAllIfNotSet
in interface AllFieldMapper.IncludeInAll
value
public String value(org.apache.lucene.document.Fieldable field)
- Description copied from interface:
FieldMapper
- Returns the actual value of the field.
- Specified by:
value
in interface FieldMapper<String>
valueFromString
public String valueFromString(String value)
- Specified by:
valueFromString
in interface FieldMapper<String>
valueAsString
public String valueAsString(org.apache.lucene.document.Fieldable field)
- Description copied from interface:
FieldMapper
- Returns the actual value of the field as string.
- Specified by:
valueAsString
in interface FieldMapper<String>
indexedValue
public String indexedValue(String value)
- Description copied from interface:
FieldMapper
- Returns the indexed value.
- Specified by:
indexedValue
in interface FieldMapper<String>
- Overrides:
indexedValue
in class AbstractFieldMapper<String>
customBoost
protected boolean customBoost()
- Description copied from class:
AbstractFieldMapper
- Derived classes can override it to specify that boost value is set by derived classes.
- Overrides:
customBoost
in class AbstractFieldMapper<String>
getPositionOffsetGap
public int getPositionOffsetGap()
searchQuoteAnalyzer
public org.apache.lucene.analysis.Analyzer searchQuoteAnalyzer()
- Description copied from interface:
FieldMapper
- The analyzer that will be used for quoted search on the field.
- Specified by:
searchQuoteAnalyzer
in interface FieldMapper<String>
- Overrides:
searchQuoteAnalyzer
in class AbstractFieldMapper<String>
nullValueFilter
public org.apache.lucene.search.Filter nullValueFilter()
- Description copied from interface:
FieldMapper
- Null value filter, returns null if there is no null value associated with the field.
- Specified by:
nullValueFilter
in interface FieldMapper<String>
- Overrides:
nullValueFilter
in class AbstractFieldMapper<String>
parseCreateField
protected org.apache.lucene.document.Field parseCreateField(ParseContext context)
throws IOException
- Specified by:
parseCreateField
in class AbstractFieldMapper<String>
- Throws:
IOException
contentType
protected String contentType()
- Specified by:
contentType
in class AbstractFieldMapper<String>
merge
public void merge(Mapper mergeWith,
MergeContext mergeContext)
throws MergeMappingException
- Specified by:
merge
in interface Mapper
- Overrides:
merge
in class AbstractFieldMapper<String>
- Throws:
MergeMappingException
doXContentBody
protected void doXContentBody(XContentBuilder builder)
throws IOException
- Overrides:
doXContentBody
in class AbstractFieldMapper<String>
- Throws:
IOException
Copyright © 2009-2012. All Rights Reserved.