Class ObjectParserHelper<Value,Context>
java.lang.Object
org.elasticsearch.common.xcontent.ObjectParserHelper<Value,Context>
This class provides helpers for
ObjectParser
that allow dealing with
classes outside of the xcontent dependencies.-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
declareRawObject(org.elasticsearch.common.xcontent.AbstractObjectParser<Value,Context> parser, BiConsumer<Value,BytesReference> consumer, org.elasticsearch.common.xcontent.ParseField field)
Helper to declare an object that will be parsed into aBytesReference
void
declareRawObjectOrNull(org.elasticsearch.common.xcontent.AbstractObjectParser<Value,Context> parser, BiConsumer<Value,BytesReference> consumer, org.elasticsearch.common.xcontent.ParseField field)
-
Constructor Details
-
ObjectParserHelper
public ObjectParserHelper()
-
-
Method Details
-
declareRawObject
public void declareRawObject(org.elasticsearch.common.xcontent.AbstractObjectParser<Value,Context> parser, BiConsumer<Value,BytesReference> consumer, org.elasticsearch.common.xcontent.ParseField field)Helper to declare an object that will be parsed into aBytesReference
-
declareRawObjectOrNull
public void declareRawObjectOrNull(org.elasticsearch.common.xcontent.AbstractObjectParser<Value,Context> parser, BiConsumer<Value,BytesReference> consumer, org.elasticsearch.common.xcontent.ParseField field)
-