Package org.elasticsearch.index.mapper
Class Mapper
java.lang.Object
org.elasticsearch.index.mapper.Mapper
- All Implemented Interfaces:
java.lang.Iterable<Mapper>
,org.elasticsearch.common.xcontent.ToXContent
,org.elasticsearch.common.xcontent.ToXContentFragment
- Direct Known Subclasses:
FieldAliasMapper
,FieldMapper
,ObjectMapper
public abstract class Mapper extends java.lang.Object implements org.elasticsearch.common.xcontent.ToXContentFragment, java.lang.Iterable<Mapper>
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
Mapper.Builder<T extends Mapper.Builder,Y extends Mapper>
static class
Mapper.BuilderContext
static interface
Mapper.TypeParser
-
Field Summary
-
Constructor Summary
Constructors Constructor Description Mapper(java.lang.String simpleName)
-
Method Summary
Modifier and Type Method Description abstract Mapper
merge(Mapper mergeWith)
Return the merge ofmergeWith
into this.abstract java.lang.String
name()
Returns the canonical name which uniquely identifies the mapper against other mappers in a type.java.lang.String
simpleName()
Returns the simple name, which identifies this mapper against other mappers at the same level in the mappers hierarchy TODO: make this protected once Mapper and FieldMapper are merged togetherabstract java.lang.String
typeName()
Returns a name representing the type of this mapper.abstract Mapper
updateFieldType(java.util.Map<java.lang.String,MappedFieldType> fullNameToFieldType)
Update the field type of this mapper.
-
Constructor Details
-
Mapper
public Mapper(java.lang.String simpleName)
-
-
Method Details
-
simpleName
public final java.lang.String simpleName()Returns the simple name, which identifies this mapper against other mappers at the same level in the mappers hierarchy TODO: make this protected once Mapper and FieldMapper are merged together -
name
public abstract java.lang.String name()Returns the canonical name which uniquely identifies the mapper against other mappers in a type. -
typeName
public abstract java.lang.String typeName()Returns a name representing the type of this mapper. -
merge
Return the merge ofmergeWith
into this. Boththis
andmergeWith
will be left unmodified. -
updateFieldType
public abstract Mapper updateFieldType(java.util.Map<java.lang.String,MappedFieldType> fullNameToFieldType)Update the field type of this mapper. This is necessary because some mapping updates can modify mappings across several types. This method must return a copy of the mapper so that the current mapper is not modified.
-