Uses of Class
com.fasterxml.jackson.core.JsonParser
Packages that use JsonParser
Package
Description
Main public API classes of the core streaming JSON
processor: most importantly
JsonFactory
used for constructing
JSON parser (JsonParser
)
and generator
(JsonGenerator
)
instances.Base classes used by concrete Parser and Generator implementations;
contain functionality that is not specific to JSON or input
abstraction (byte vs char).
Package for some of
JsonProcessingException
subtypes contained by streaming API.Package that contains interfaces needed for dynamic, pluggable
format (auto)detection; as well as basic utility classes for
simple format detection functionality.
JSON-specific parser and generator implementation classes that
Jackson defines and uses.
Non-blocking ("async") JSON parser implementation.
Utility classes used by Jackson Core functionality.
-
Uses of JsonParser in com.fasterxml.jackson.core
Methods in com.fasterxml.jackson.core that return JsonParserModifier and TypeMethodDescriptionprotected JsonParser
JsonFactory._createParser
(byte[] data, int offset, int len, IOContext ctxt) Overridable factory method that actually instantiates parser using givenReader
object for reading content passed as raw byte array.protected JsonParser
JsonFactory._createParser
(char[] data, int offset, int len, IOContext ctxt, boolean recyclable) Overridable factory method that actually instantiates parser using givenchar[]
object for accessing content.protected JsonParser
JsonFactory._createParser
(DataInput input, IOContext ctxt) Optional factory method, expected to be overriddenprotected JsonParser
JsonFactory._createParser
(InputStream in, IOContext ctxt) Overridable factory method that actually instantiates desired parser givenInputStream
and context object.protected JsonParser
JsonFactory._createParser
(Reader r, IOContext ctxt) Overridable factory method that actually instantiates parser using givenReader
object for reading content.JsonParser.configure
(JsonParser.Feature f, boolean state) Method for enabling or disabling specified feature (checkJsonParser.Feature
for list of features)JsonFactory.createJsonParser
(byte[] data) Deprecated.JsonFactory.createJsonParser
(byte[] data, int offset, int len) Deprecated.Since 2.2, useJsonFactory.createParser(byte[],int,int)
instead.JsonFactory.createJsonParser
(File f) Deprecated.Since 2.2, useJsonFactory.createParser(File)
instead.JsonFactory.createJsonParser
(InputStream in) Deprecated.Since 2.2, useJsonFactory.createParser(InputStream)
instead.JsonFactory.createJsonParser
(Reader r) Deprecated.Since 2.2, useJsonFactory.createParser(Reader)
instead.JsonFactory.createJsonParser
(String content) Deprecated.Since 2.2, useJsonFactory.createParser(String)
instead.JsonFactory.createJsonParser
(URL url) Deprecated.Since 2.2, useJsonFactory.createParser(URL)
instead.JsonFactory.createNonBlockingByteArrayParser()
Optional method for constructing parser for non-blocking parsing viaByteArrayFeeder
interface (accessed usinggetNonBlockingInputFeeder()
from constructed instance).abstract JsonParser
TokenStreamFactory.createNonBlockingByteArrayParser()
Optional method for constructing parser for non-blocking parsing viaByteArrayFeeder
interface (accessed usinggetNonBlockingInputFeeder()
from constructed instance).JsonFactory.createNonBlockingByteBufferParser()
Optional method for constructing parser for non-blocking parsing viaByteBufferFeeder
interface (accessed usinggetNonBlockingInputFeeder()
from constructed instance).abstract JsonParser
TokenStreamFactory.createNonBlockingByteBufferParser()
Optional method for constructing parser for non-blocking parsing viaByteBufferFeeder
interface (accessed usinggetNonBlockingInputFeeder()
from constructed instance).JsonFactory.createParser
(byte[] data) Method for constructing parser for parsing the contents of given byte array.JsonFactory.createParser
(byte[] data, int offset, int len) Method for constructing parser for parsing the contents of given byte array.JsonFactory.createParser
(char[] content) Method for constructing parser for parsing contents of given char array.JsonFactory.createParser
(char[] content, int offset, int len) Method for constructing parser for parsing contents of given char array.JsonFactory.createParser
(DataInput in) Optional method for constructing parser for reading contents from specifiedDataInput
instance.JsonFactory.createParser
(File f) Method for constructing JSON parser instance to parse contents of specified file.JsonFactory.createParser
(InputStream in) Method for constructing JSON parser instance to parse the contents accessed via specified input stream.JsonFactory.createParser
(Reader r) Method for constructing parser for parsing the contents accessed via specified Reader.JsonFactory.createParser
(String content) Method for constructing parser for parsing contents of given String.JsonFactory.createParser
(URL url) Method for constructing JSON parser instance to parse contents of resource reference by given URL.abstract JsonParser
TokenStreamFactory.createParser
(byte[] data) abstract JsonParser
TokenStreamFactory.createParser
(byte[] data, int offset, int len) abstract JsonParser
TokenStreamFactory.createParser
(char[] content) abstract JsonParser
TokenStreamFactory.createParser
(char[] content, int offset, int len) abstract JsonParser
TokenStreamFactory.createParser
(DataInput in) abstract JsonParser
TokenStreamFactory.createParser
(File f) abstract JsonParser
TokenStreamFactory.createParser
(InputStream in) abstract JsonParser
TokenStreamFactory.createParser
(Reader r) abstract JsonParser
TokenStreamFactory.createParser
(String content) abstract JsonParser
TokenStreamFactory.createParser
(URL url) JsonParser.disable
(JsonParser.Feature f) Method for disabling specified feature (checkJsonParser.Feature
for list of features)JsonParser.enable
(JsonParser.Feature f) Method for enabling specified parser feature (checkJsonParser.Feature
for list of features)JsonParseException.getProcessor()
JsonParser.overrideFormatFeatures
(int values, int mask) Bulk set method for (re)setting states ofFormatFeature
s, by specifying values (set / clear) along with a mask, to determine which features to change, if any.JsonParser.overrideStdFeatures
(int values, int mask) Bulk set method for (re)setting states of features specified bymask
.JsonParser.setFeatureMask
(int mask) Deprecated.Since 2.7, useoverrideStdFeatures(int, int)
insteadabstract JsonParser
JsonParser.skipChildren()
Method that will skip all child tokens of an array or object token that the parser currently points to, iff stream points toJsonToken.START_OBJECT
orJsonToken.START_ARRAY
.TreeNode.traverse()
Method for constructing aJsonParser
instance for iterating over contents of the tree that this node is root of.TreeNode.traverse
(ObjectCodec codec) Same asTreeNode.traverse()
, but additionally passesObjectCodec
to use ifreadValueAs(Class)
is used (otherwise caller must callsetCodec(com.fasterxml.jackson.core.ObjectCodec)
on response explicitly).abstract JsonParser
ObjectCodec.treeAsTokens
(TreeNode n) Method for constructing aJsonParser
for reading contents of a JSON tree, as if it was external serialized JSON content.abstract JsonParser
TreeCodec.treeAsTokens
(TreeNode node) Methods in com.fasterxml.jackson.core with parameters of type JsonParserModifier and TypeMethodDescriptionprotected void
JsonGenerator._copyCurrentContents
(JsonParser p) protected void
JsonGenerator._copyCurrentFloatValue
(JsonParser p) Method for copying currentJsonToken.VALUE_NUMBER_FLOAT
value; overridable by format backend implementations.protected void
JsonGenerator._copyCurrentFloatValueExact
(JsonParser p) Method for copying currentJsonToken.VALUE_NUMBER_FLOAT
value; overridable by format backend implementations.protected void
JsonGenerator._copyCurrentIntValue
(JsonParser p) Method for copying currentJsonToken.VALUE_NUMBER_FLOAT
value; overridable by format backend implementations.protected void
JsonGenerator._copyCurrentStringValue
(JsonParser p) Method for copying currentJsonToken.VALUE_STRING
value; overridable by format backend implementations.void
JsonGenerator.copyCurrentEvent
(JsonParser p) Method for copying contents of the current event that the given parser instance points to.void
JsonGenerator.copyCurrentEventExact
(JsonParser p) Same asJsonGenerator.copyCurrentEvent(com.fasterxml.jackson.core.JsonParser)
with the exception that copying of numeric values tries to avoid any conversion losses; in particular for floating-point numbers.void
JsonGenerator.copyCurrentStructure
(JsonParser p) Method for copying contents of the current event and following events that it encloses the given parser instance points to.abstract <T extends TreeNode>
TObjectCodec.readTree
(JsonParser p) Method for deserializing JSON content as tree expressed using set ofTreeNode
instances.abstract <T extends TreeNode>
TTreeCodec.readTree
(JsonParser p) abstract <T> T
ObjectCodec.readValue
(JsonParser p, ResolvedType valueType) Method to deserialize JSON content into a POJO, type specified with fully resolved type object (so it can be a generic type, including containers likeCollection
andMap
).abstract <T> T
ObjectCodec.readValue
(JsonParser p, TypeReference<T> valueTypeRef) Method to deserialize JSON content into a Java type, reference to which is passed as argument.abstract <T> T
ObjectCodec.readValue
(JsonParser p, Class<T> valueType) Method to deserialize JSON content into a non-container type (it can be an array type, however): typically a bean, array or a wrapper type (likeBoolean
).abstract <T> Iterator
<T> ObjectCodec.readValues
(JsonParser p, ResolvedType valueType) Method for reading sequence of Objects from parser stream, all with same specified value type.abstract <T> Iterator
<T> ObjectCodec.readValues
(JsonParser p, TypeReference<T> valueTypeRef) Method for reading sequence of Objects from parser stream, all with same specified value type.abstract <T> Iterator
<T> ObjectCodec.readValues
(JsonParser p, Class<T> valueType) Method for reading sequence of Objects from parser stream, all with same specified value type.JsonParseException.withParser
(JsonParser p) Fluent method that may be used to assign originatingJsonParser
, to be accessed usingJsonParseException.getProcessor()
.Constructors in com.fasterxml.jackson.core with parameters of type JsonParserModifierConstructorDescriptionJsonParseException
(JsonParser p, String msg) Constructor that uses current parsing location as location, and sets processor (accessible viaJsonParseException.getProcessor()
) to specified parser.JsonParseException
(JsonParser p, String msg, JsonLocation loc) JsonParseException
(JsonParser p, String msg, JsonLocation loc, Throwable root) JsonParseException
(JsonParser p, String msg, Throwable root) -
Uses of JsonParser in com.fasterxml.jackson.core.base
Subclasses of JsonParser in com.fasterxml.jackson.core.baseModifier and TypeClassDescriptionclass
Intermediate base class used by all JacksonJsonParser
implementations.class
Intermediate base class used by all JacksonJsonParser
implementations, but does not add any additional fields that depend on particular method of obtaining input.Methods in com.fasterxml.jackson.core.base that return JsonParserModifier and TypeMethodDescriptionParserBase.disable
(JsonParser.Feature f) ParserBase.enable
(JsonParser.Feature f) ParserBase.overrideStdFeatures
(int values, int mask) ParserBase.setFeatureMask
(int newMask) Deprecated.ParserMinimalBase.skipChildren()
-
Uses of JsonParser in com.fasterxml.jackson.core.exc
Fields in com.fasterxml.jackson.core.exc declared as JsonParserMethods in com.fasterxml.jackson.core.exc that return JsonParserMethods in com.fasterxml.jackson.core.exc with parameters of type JsonParserModifier and TypeMethodDescriptionInputCoercionException.withParser
(JsonParser p) Fluent method that may be used to assign originatingJsonParser
, to be accessed usingStreamReadException.getProcessor()
.abstract StreamReadException
StreamReadException.withParser
(JsonParser p) Fluent method that may be used to assign originatingJsonParser
, to be accessed usingStreamReadException.getProcessor()
.Constructors in com.fasterxml.jackson.core.exc with parameters of type JsonParserModifierConstructorDescriptionInputCoercionException
(JsonParser p, String msg, JsonToken inputType, Class<?> targetType) Constructor that uses current parsing location as location, and sets processor (accessible viaStreamReadException.getProcessor()
) to specified parser.protected
StreamReadException
(JsonParser p, String msg) protected
StreamReadException
(JsonParser p, String msg, JsonLocation loc) protected
StreamReadException
(JsonParser p, String msg, JsonLocation loc, Throwable rootCause) protected
StreamReadException
(JsonParser p, String msg, Throwable root) -
Uses of JsonParser in com.fasterxml.jackson.core.filter
Subclasses of JsonParser in com.fasterxml.jackson.core.filterModifier and TypeClassDescriptionclass
SpecializedJsonParserDelegate
that allows use ofTokenFilter
for outputting a subset of content that is visible to callerMethods in com.fasterxml.jackson.core.filter that return JsonParserModifier and TypeMethodDescriptionFilteringParserDelegate.skipChildren()
Need to override, re-implement similar to how method defined inParserMinimalBase
, to keep state correct here.Methods in com.fasterxml.jackson.core.filter with parameters of type JsonParserModifier and TypeMethodDescriptionboolean
TokenFilter.includeValue
(JsonParser p) Call made when verifying whether a scalar value is being read from a parser.Constructors in com.fasterxml.jackson.core.filter with parameters of type JsonParserModifierConstructorDescriptionFilteringParserDelegate
(JsonParser p, TokenFilter f, boolean includePath, boolean allowMultipleMatches) Deprecated.FilteringParserDelegate
(JsonParser p, TokenFilter f, TokenFilter.Inclusion inclusion, boolean allowMultipleMatches) -
Uses of JsonParser in com.fasterxml.jackson.core.format
Methods in com.fasterxml.jackson.core.format that return JsonParser -
Uses of JsonParser in com.fasterxml.jackson.core.io
Constructors in com.fasterxml.jackson.core.io with parameters of type JsonParser -
Uses of JsonParser in com.fasterxml.jackson.core.json
Subclasses of JsonParser in com.fasterxml.jackson.core.jsonModifier and TypeClassDescriptionclass
This is a concrete implementation ofJsonParser
, which is based on aReader
to handle low-level character conversion tasks.class
This is a concrete implementation ofJsonParser
, which is based on aDataInput
as the input source.class
This is a concrete implementation ofJsonParser
, which is based on aInputStream
as the input source.Methods in com.fasterxml.jackson.core.json that return JsonParserModifier and TypeMethodDescriptionByteSourceJsonBootstrapper.constructParser
(int parserFeatures, ObjectCodec codec, ByteQuadsCanonicalizer rootByteSymbols, CharsToNameCanonicalizer rootCharSymbols, int factoryFeatures) Methods in com.fasterxml.jackson.core.json with parameters of type JsonParser -
Uses of JsonParser in com.fasterxml.jackson.core.json.async
Subclasses of JsonParser in com.fasterxml.jackson.core.json.asyncModifier and TypeClassDescriptionclass
Non-blocking parser implementation for JSON content that takes its input viaByteBuffer
instance(s) passed.class
Non-blocking parser implementation for JSON content that takes its input viabyte[]
passed.class
Intermediate base class for non-blocking JSON parsers.class
Non-blocking parser base implementation for JSON content. -
Uses of JsonParser in com.fasterxml.jackson.core.util
Subclasses of JsonParser in com.fasterxml.jackson.core.utilModifier and TypeClassDescriptionclass
Helper class that implements delegation pattern forJsonParser
, to allow for simple overridability of basic parsing functionality.class
Helper class that can be used to sequence multiple physicalJsonParser
s to create a single logical sequence of tokens, as a singleJsonParser
.Fields in com.fasterxml.jackson.core.util declared as JsonParserModifier and TypeFieldDescriptionprotected final JsonParser[]
JsonParserSequence._parsers
Parsers other than the first one (which is initially assigned as delegate)protected JsonParser
JsonParserDelegate.delegate
Delegate object that method calls are delegated to.Methods in com.fasterxml.jackson.core.util that return JsonParserModifier and TypeMethodDescriptionJsonParserDelegate.delegate()
Accessor for getting the immediateJsonParser
this parser delegates calls to.JsonParserDelegate.disable
(JsonParser.Feature f) JsonParserDelegate.enable
(JsonParser.Feature f) JsonParserDelegate.overrideFormatFeatures
(int values, int mask) JsonParserDelegate.overrideStdFeatures
(int values, int mask) JsonParserDelegate.setFeatureMask
(int mask) Deprecated.JsonParserDelegate.skipChildren()
JsonParserSequence.skipChildren()
Need to override, re-implement similar to how method defined inParserMinimalBase
, to keep state correct here.Methods in com.fasterxml.jackson.core.util with parameters of type JsonParserModifier and TypeMethodDescriptionvoid
JsonGeneratorDelegate.copyCurrentEvent
(JsonParser p) void
JsonGeneratorDelegate.copyCurrentStructure
(JsonParser p) static JsonParserSequence
JsonParserSequence.createFlattened
(boolean checkForExistingToken, JsonParser first, JsonParser second) Method that will construct a sequence (possibly a sequence) that contains all given sub-parsers.static JsonParserSequence
JsonParserSequence.createFlattened
(JsonParser first, JsonParser second) Deprecated.Method parameters in com.fasterxml.jackson.core.util with type arguments of type JsonParserModifier and TypeMethodDescriptionprotected void
JsonParserSequence.addFlattenedActiveParsers
(List<JsonParser> listToAddIn) Constructors in com.fasterxml.jackson.core.util with parameters of type JsonParserModifierConstructorDescriptionprotected
JsonParserSequence
(boolean checkForExistingToken, JsonParser[] parsers) protected
JsonParserSequence
(JsonParser[] parsers) Deprecated.
JsonFactory.createParser(byte[])
instead.