Skip to main content

Arun Gupta: JsonParser and JsonReader - Streaming and Object Readers in Java API for JSON Processing (TOTD #206)

JsonReader reads a JSON object or array from an input source. This provides DOM access to the JSON structure. JsonParser provides forward, ready-only access to JSON data in a streaming way. The parser can be created from InputStream and Reader... Here is a table with code fragments for parsing some common JSON using Object Model and events generated from Streaming API...

Community: GlassFish