Package org.opensearch.index.mapper
Class FlatObjectFieldMapper
java.lang.Object
org.opensearch.index.mapper.Mapper
org.opensearch.index.mapper.FieldMapper
org.opensearch.index.mapper.DynamicKeyFieldMapper
org.opensearch.index.mapper.FlatObjectFieldMapper
- All Implemented Interfaces:
Cloneable
,Iterable<Mapper>
,org.opensearch.core.xcontent.ToXContent
,org.opensearch.core.xcontent.ToXContentFragment
A field mapper for flat_objects.
This mapper accepts JSON object and treat as string fields in one index.
- Opensearch.internal:
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic class
The builder for the flat_object field mapper using default parametersstatic class
In flat_object field mapper, field type is similar to keyword field type Cannot be tokenized, can OmitNorms, and can setIndexOption.static class
FlatObjectFieldType is the parent field type.static final class
flat_object fields type contains its own fieldType, one valueFieldType and one valueAndPathFieldTypestatic class
Creates a new TypeParser for flatObjectFieldMapper that does not use ParameterizedFieldMapperNested classes/interfaces inherited from class org.opensearch.index.mapper.FieldMapper
FieldMapper.CopyTo, FieldMapper.MultiFields
Nested classes/interfaces inherited from class org.opensearch.index.mapper.Mapper
Mapper.BuilderContext
Nested classes/interfaces inherited from interface org.opensearch.core.xcontent.ToXContent
org.opensearch.core.xcontent.ToXContent.DelegatingMapParams, org.opensearch.core.xcontent.ToXContent.MapParams, org.opensearch.core.xcontent.ToXContent.Params
-
Field Summary
Modifier and TypeFieldDescriptionstatic final String
static final FlatObjectFieldMapper.TypeParser
Fields inherited from class org.opensearch.index.mapper.FieldMapper
COERCE_SETTING, copyTo, fieldType, IGNORE_MALFORMED_SETTING, mappedFieldType, multiFields
Fields inherited from interface org.opensearch.core.xcontent.ToXContent
EMPTY_PARAMS
-
Method Summary
Modifier and TypeMethodDescriptionprotected FlatObjectFieldMapper
clone()
protected String
iterator()
keyedFieldType
(String key) protected void
mergeOptions
(FieldMapper other, List<String> conflicts) Merge type-specific options and check for incompatible settings in mappings to be mergedprotected void
parseCreateField
(ParseContext context) Parse the field value and populate the fields onParseContext.doc()
.Methods inherited from class org.opensearch.index.mapper.FieldMapper
copyTo, createFieldNamesField, docValuesByDefault, doValidate, doXContentAnalyzers, doXContentBody, indexedByDefault, indexOptionToString, merge, multiFields, name, parse, parsesArrayValue, storedByDefault, toXContent, typeName, validate
Methods inherited from class org.opensearch.index.mapper.Mapper
hasIndexCreated, simpleName
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface java.lang.Iterable
forEach, spliterator
Methods inherited from interface org.opensearch.core.xcontent.ToXContentFragment
isFragment
-
Field Details
-
CONTENT_TYPE
- See Also:
-
PARSER
-
-
Method Details
-
keyedFieldType
- Specified by:
keyedFieldType
in classDynamicKeyFieldMapper
-
clone
- Overrides:
clone
in classFieldMapper
-
mergeOptions
Description copied from class:FieldMapper
Merge type-specific options and check for incompatible settings in mappings to be merged- Specified by:
mergeOptions
in classFieldMapper
-
fieldType
- Overrides:
fieldType
in classFieldMapper
-
parseCreateField
Description copied from class:FieldMapper
Parse the field value and populate the fields onParseContext.doc()
.Implementations of this method should ensure that on failing to parse parser.currentToken() must be the current failing token
- Specified by:
parseCreateField
in classFieldMapper
- Throws:
IOException
-
iterator
- Specified by:
iterator
in interfaceIterable<Mapper>
- Overrides:
iterator
in classFieldMapper
-
contentType
- Specified by:
contentType
in classFieldMapper
-