public class JsonNodeToObjectNodeConverter extends Object implements ContentTypeConverter<com.fasterxml.jackson.databind.JsonNode,com.fasterxml.jackson.databind.node.ObjectNode>
ContentTypeConverter
implementation that converts a JsonNode
object into an ObjectNode
.
Intended to simplify JSON-typed event upcasters, which generally deal with an ObjectNode
as the event.
Will succeed if the JsonNode
has a node type of JsonNodeType.OBJECT
.
Constructor and Description |
---|
JsonNodeToObjectNodeConverter() |
Modifier and Type | Method and Description |
---|---|
com.fasterxml.jackson.databind.node.ObjectNode |
convert(com.fasterxml.jackson.databind.JsonNode original)
Converts the given object into another.
|
Class<com.fasterxml.jackson.databind.JsonNode> |
expectedSourceType()
The expected type of input data.
|
Class<com.fasterxml.jackson.databind.node.ObjectNode> |
targetType()
The returned type of IntermediateRepresentation
|
public Class<com.fasterxml.jackson.databind.JsonNode> expectedSourceType()
ContentTypeConverter
expectedSourceType
in interface ContentTypeConverter<com.fasterxml.jackson.databind.JsonNode,com.fasterxml.jackson.databind.node.ObjectNode>
public Class<com.fasterxml.jackson.databind.node.ObjectNode> targetType()
ContentTypeConverter
targetType
in interface ContentTypeConverter<com.fasterxml.jackson.databind.JsonNode,com.fasterxml.jackson.databind.node.ObjectNode>
public com.fasterxml.jackson.databind.node.ObjectNode convert(com.fasterxml.jackson.databind.JsonNode original)
ContentTypeConverter
SerializedObject
instance.convert
in interface ContentTypeConverter<com.fasterxml.jackson.databind.JsonNode,com.fasterxml.jackson.databind.node.ObjectNode>
original
- the value to convertCopyright © 2010–2023. All rights reserved.