- All Known Implementing Classes:
ObjectReadContext.Base
public interface ObjectReadContext
Defines API for accessing configuration and state exposed by
higher level databind
functionality during read (token stream to Object deserialization) process.
Access is mostly needed during construction of
JsonParser instances by TokenStreamFactory.- Since:
- 3.0
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic classDefault no-op implementation. -
Method Summary
Modifier and TypeMethodDescriptionMethod for construct Array nodes for Tree Model instances.Method for construct Object nodes for Tree Model instances.default JsonParsercreateParser(byte[] content) default JsonParsercreateParser(byte[] content, int offset, int length) default JsonParserdefault JsonParserdefault JsonParsercreateParser(String content) static ObjectReadContextempty()intgetFormatReadFeatures(int defaults) intgetStreamReadFeatures(int defaults) <T extends TreeNode>
T<T> TreadValue(JsonParser p, Class<T> valueType) <T> TreadValue(JsonParser p, ResolvedType type) <T> TreadValue(JsonParser p, TypeReference<T> valueTypeRef) default JsonParserConvenience method for traversing over givenTreeNodeby exposing contents as aJsonParser.
-
Method Details
-
empty
-
getSchema
FormatSchema getSchema() -
getStreamReadFeatures
int getStreamReadFeatures(int defaults) -
getFormatReadFeatures
int getFormatReadFeatures(int defaults) -
tokenStreamFactory
TokenStreamFactory tokenStreamFactory() -
streamReadConstraints
StreamReadConstraints streamReadConstraints() -
createParser
- Throws:
JacksonException
-
createParser
- Throws:
JacksonException
-
createParser
- Throws:
JacksonException
-
createParser
- Throws:
JacksonException
-
createParser
- Throws:
JacksonException
-
createArrayNode
ArrayTreeNode createArrayNode()Method for construct Array nodes for Tree Model instances.- Returns:
- Array node created
-
createObjectNode
ObjectTreeNode createObjectNode()Method for construct Object nodes for Tree Model instances.- Returns:
- Object node created
-
readTree
- Throws:
JacksonException
-
treeAsTokens
Convenience method for traversing over givenTreeNodeby exposing contents as aJsonParser.NOTE! Returned parser has not been advanced to the first token; caller has to do this.
- Parameters:
n- Node to traverse over- Returns:
- Parser that iterates over contents of given node
-
readValue
- Throws:
JacksonException
-
readValue
- Throws:
JacksonException
-
readValue
- Throws:
JacksonException
-