Class InternalNodeMapper.WrapperForSerializer
java.lang.Object
com.fasterxml.jackson.databind.JsonSerializable.Base
com.fasterxml.jackson.databind.node.InternalNodeMapper.WrapperForSerializer
- All Implemented Interfaces:
JsonSerializable
- Enclosing class:
InternalNodeMapper
Intermediate serializer we need to implement non-recursive serialization of
BaseJsonNode.
NOTE: not designed as thread-safe; instances must NOT be shared or reused.
- Since:
- 2.14
-
Nested Class Summary
Nested classes/interfaces inherited from interface com.fasterxml.jackson.databind.JsonSerializable
JsonSerializable.Base -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected void_serializeNonRecursive(com.fasterxml.jackson.core.JsonGenerator g, JsonNode node) protected void_serializeNonRecursive(com.fasterxml.jackson.core.JsonGenerator g, InternalNodeMapper.IteratorStack stack, Iterator<?> rootIterator) voidserialize(com.fasterxml.jackson.core.JsonGenerator g, SerializerProvider ctxt) Serialization method called when no additional type information is to be included in serialization.voidserializeWithType(com.fasterxml.jackson.core.JsonGenerator g, SerializerProvider ctxt, TypeSerializer typeSer) Serialization method called when additional type information is expected to be included in serialization, for deserialization to use.Methods inherited from class com.fasterxml.jackson.databind.JsonSerializable.Base
isEmpty
-
Field Details
-
_root
-
_context
-
-
Constructor Details
-
WrapperForSerializer
-
-
Method Details
-
serialize
public void serialize(com.fasterxml.jackson.core.JsonGenerator g, SerializerProvider ctxt) throws IOException Description copied from interface:JsonSerializableSerialization method called when no additional type information is to be included in serialization.- Throws:
IOException
-
serializeWithType
public void serializeWithType(com.fasterxml.jackson.core.JsonGenerator g, SerializerProvider ctxt, TypeSerializer typeSer) throws IOException Description copied from interface:JsonSerializableSerialization method called when additional type information is expected to be included in serialization, for deserialization to use.Usually implementation consists of a call to
TypeSerializer.writeTypePrefix(com.fasterxml.jackson.core.JsonGenerator, com.fasterxml.jackson.core.type.WritableTypeId)followed by serialization of contents, followed by a call toTypeSerializer.writeTypeSuffix(com.fasterxml.jackson.core.JsonGenerator, com.fasterxml.jackson.core.type.WritableTypeId)). Details of the type id argument to pass depend on shape of JSON Object used (Array, Object or scalar like String/Number/Boolean).Note that some types (most notably, "natural" types: String, Integer, Double and Boolean) never include type information.
- Throws:
IOException
-
_serializeNonRecursive
protected void _serializeNonRecursive(com.fasterxml.jackson.core.JsonGenerator g, JsonNode node) throws IOException - Throws:
IOException
-
_serializeNonRecursive
protected void _serializeNonRecursive(com.fasterxml.jackson.core.JsonGenerator g, InternalNodeMapper.IteratorStack stack, Iterator<?> rootIterator) throws IOException - Throws:
IOException
-