|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.objsys.asn1j.runtime.Asn1MessageBufferBase com.objsys.asn1j.runtime.Asn1JsonDecodeBuffer
public class Asn1JsonDecodeBuffer
Decode buffer for decoding JSON-encoded data.
Field Summary |
---|
Fields inherited from class com.objsys.asn1j.runtime.Asn1MessageBufferBase |
---|
context, mTypeCode |
Constructor Summary | |
---|---|
Asn1JsonDecodeBuffer(java.io.InputStream stream)
Create Asn1JsonDecodeBuffer on the given input byte stream. |
|
Asn1JsonDecodeBuffer(java.io.Reader reader)
Create Asn1JsonDecodeBuffer on the given reader. |
Method Summary | |
---|---|
boolean |
nextCharacterIs(char c)
Returns true if the next character is the given character. |
boolean |
nextCharacterIsNot(char c)
Returns true if the next character not the given character. |
boolean |
readBoolean()
Reads "true" or "false" from input and returns the corresponding boolean value. |
void |
readCharacter(char matchChar)
Read the given character from input. |
int |
readInt()
Convenience method equivalent to Integer.parseInt( this.readNumber() ) |
java.lang.String |
readJsonValue()
Read the next JSON value from the input. |
void |
readNull()
Reads "null" from input. |
java.lang.String |
readNumber()
Read a JSON number from input. |
java.lang.String |
readString()
Read a JSON string from the input. |
void |
readString(java.lang.String expectedValue)
Convenience method which invokes readString() and throws an exception if the result is not the expectedValue. |
int |
seekCharacter()
Seeks past whitespace in the input to find the next input character. |
void |
skipWhitespace()
Skip (read past) all whitespace on input until there is no more input or a nonwhitespace character is the next character of input. |
Methods inherited from class com.objsys.asn1j.runtime.Asn1MessageBufferBase |
---|
getContext, hexDump, hexDump, setKey, setTypeCode |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Asn1JsonDecodeBuffer(java.io.Reader reader)
public Asn1JsonDecodeBuffer(java.io.InputStream stream)
stream
- Method Detail |
---|
public void skipWhitespace() throws java.io.IOException
java.io.IOException
public boolean nextCharacterIs(char c) throws java.io.IOException
java.io.IOException
public boolean nextCharacterIsNot(char c) throws java.io.IOException
java.io.IOException
public int seekCharacter() throws java.io.IOException
java.io.IOException
public void readCharacter(char matchChar) throws java.io.IOException
matchChar
- The character expected on input.
Asn1Exception
- if the expected character token is not present
java.io.IOException
public int readInt() throws java.io.IOException
java.io.IOException
public java.lang.String readNumber() throws java.io.IOException
java.io.IOException
public java.lang.String readJsonValue() throws java.io.IOException
Asn1Exception
- if a JSON value cannot be read.
java.io.IOException
public void readString(java.lang.String expectedValue) throws java.io.IOException
expectedValue
-
java.io.IOException
public java.lang.String readString() throws java.io.IOException
Asn1Exception
- if a JSON string is not on input.
java.io.IOException
public boolean readBoolean() throws java.io.IOException
Asn1Exception
- if a literal true or false value is not on input.
java.io.IOException
public void readNull() throws java.io.IOException
Asn1Exception
- if a literal null value is not on input.
java.io.IOException
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |