Package com.fasterxml.jackson.core
Class TreeCodec
- java.lang.Object
-
- com.fasterxml.jackson.core.TreeCodec
-
- Direct Known Subclasses:
ObjectCodec
public abstract class TreeCodec extends java.lang.Object
Interface that defines objects that can read and writeTreeNode
instances using Streaming API.- Since:
- 2.3
-
-
Constructor Summary
Constructors Constructor Description TreeCodec()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description abstract TreeNode
createArrayNode()
abstract TreeNode
createObjectNode()
TreeNode
missingNode()
TreeNode
nullNode()
abstract <T extends TreeNode>
TreadTree(JsonParser p)
abstract JsonParser
treeAsTokens(TreeNode node)
abstract void
writeTree(JsonGenerator g, TreeNode tree)
-
-
-
Method Detail
-
readTree
public abstract <T extends TreeNode> T readTree(JsonParser p) throws java.io.IOException, JsonProcessingException
- Throws:
java.io.IOException
JsonProcessingException
-
writeTree
public abstract void writeTree(JsonGenerator g, TreeNode tree) throws java.io.IOException, JsonProcessingException
- Throws:
java.io.IOException
JsonProcessingException
-
missingNode
public TreeNode missingNode()
- Returns:
- Node that represents "missing" node during traversal: something referenced but that does not exist in content model
- Since:
- 2.10
-
nullNode
public TreeNode nullNode()
- Returns:
- Node that represents explict
null
value in content - Since:
- 2.10
-
createArrayNode
public abstract TreeNode createArrayNode()
-
createObjectNode
public abstract TreeNode createObjectNode()
-
treeAsTokens
public abstract JsonParser treeAsTokens(TreeNode node)
-
-