Class MappingMetaData
- java.lang.Object
-
- org.elasticsearch.cluster.AbstractDiffable<MappingMetaData>
-
- org.elasticsearch.cluster.metadata.MappingMetaData
-
- All Implemented Interfaces:
Diffable<MappingMetaData>,Writeable
public class MappingMetaData extends AbstractDiffable<MappingMetaData>
Mapping configuration for a type.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classMappingMetaData.Routing-
Nested classes/interfaces inherited from interface org.elasticsearch.common.io.stream.Writeable
Writeable.Reader<V>, Writeable.Writer<V>
-
-
Constructor Summary
Constructors Constructor Description MappingMetaData(String type, Map<String,Object> mapping)MappingMetaData(CompressedXContent mapping)MappingMetaData(StreamInput in)MappingMetaData(DocumentMapper docMapper)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(Object o)Map<String,Object>getSourceAsMap()Converts the serialized compressed form of the mappings into a parsed map.inthashCode()static Diff<MappingMetaData>readDiffFrom(StreamInput in)MappingMetaData.Routingrouting()CompressedXContentsource()Map<String,Object>sourceAsMap()Converts the serialized compressed form of the mappings into a parsed map.Stringtype()voidwriteTo(StreamOutput out)Write this into the StreamOutput.-
Methods inherited from class org.elasticsearch.cluster.AbstractDiffable
diff, get, readDiffFrom
-
-
-
-
Constructor Detail
-
MappingMetaData
public MappingMetaData(DocumentMapper docMapper)
-
MappingMetaData
public MappingMetaData(CompressedXContent mapping)
-
MappingMetaData
public MappingMetaData(String type, Map<String,Object> mapping) throws IOException
- Throws:
IOException
-
MappingMetaData
public MappingMetaData(StreamInput in) throws IOException
- Throws:
IOException
-
-
Method Detail
-
type
public String type()
-
source
public CompressedXContent source()
-
sourceAsMap
public Map<String,Object> sourceAsMap() throws ElasticsearchParseException
Converts the serialized compressed form of the mappings into a parsed map.- Throws:
ElasticsearchParseException
-
getSourceAsMap
public Map<String,Object> getSourceAsMap() throws ElasticsearchParseException
Converts the serialized compressed form of the mappings into a parsed map.- Throws:
ElasticsearchParseException
-
routing
public MappingMetaData.Routing routing()
-
writeTo
public void writeTo(StreamOutput out) throws IOException
Description copied from interface:WriteableWrite this into the StreamOutput.- Throws:
IOException
-
readDiffFrom
public static Diff<MappingMetaData> readDiffFrom(StreamInput in) throws IOException
- Throws:
IOException
-
-