java.lang.Object | |
↳ | com.pnfsoftware.jeb.util.encoding.json.parser.JSONParser |
Parser for JSON text. Please note that JSONParser is NOT thread-safe.
Modified to support arbitrarily long integer json Numbers.
Constants | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
int | S_END | ||||||||||
int | S_INIT | ||||||||||
int | S_IN_ARRAY | ||||||||||
int | S_IN_ERROR | ||||||||||
int | S_IN_FINISHED_VALUE | ||||||||||
int | S_IN_OBJECT | ||||||||||
int | S_IN_PAIR_VALUE | ||||||||||
int | S_PASSED_PAIR_KEY |
Public Constructors | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
JSONParser() |
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
long | getPosition() | ||||||||||
Object | parse(Reader in) | ||||||||||
Object | parse(String s) | ||||||||||
Object | parse(String s, ContainerFactory containerFactory) | ||||||||||
void | parse(Reader in, ContentHandler contentHandler) | ||||||||||
void |
parse(Reader in, ContentHandler contentHandler, boolean isResume)
Stream processing of JSON text.
| ||||||||||
void | parse(String s, ContentHandler contentHandler) | ||||||||||
void | parse(String s, ContentHandler contentHandler, boolean isResume) | ||||||||||
Object |
parse(Reader in, ContainerFactory containerFactory)
Parse JSON text into java object from the input source.
| ||||||||||
void |
reset(Reader in)
Reset the parser to the initial state with a new character reader.
| ||||||||||
void |
reset()
Reset the parser to the initial state without resetting the underlying reader.
|
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From class
java.lang.Object
|
Stream processing of JSON text.
isResume | - Indicates if it continues previous parsing operation. If set to true, resume parsing the old stream, and parameter 'in' will be ignored. If this method is called for the first time in this instance, isResume will be ignored. |
---|
IOException | |
ParseException | |
IOException |
Parse JSON text into java object from the input source.
containerFactory | - Use this factory to create your own JSON object and JSON array containers. |
---|
IOException | |
ParseException | |
IOException |
Reset the parser to the initial state with a new character reader.
in | - The new character reader. |
---|
IOException | |
ParseException |
Reset the parser to the initial state without resetting the underlying reader.