public class JsonToken
extends Object
A JSON token, with a type, line / column information, and the text of that token.
| Type Params | Return Type | Name and description |
|---|---|---|
|
public long |
getEndColumn()Returns the ending column of this token. |
|
public long |
getEndLine()Returns the ending line of this token. |
|
public long |
getStartColumn()Returns the starting column of this token. |
|
public long |
getStartLine()Returns the starting line of this token. |
|
public String |
getText()Returns the token text. |
|
public JsonTokenType |
getType()Returns the token type. |
|
public Object |
getValue()Return the value represented by this token (i.e. a number, a string, a boolean or null). |
|
public void |
setEndColumn(long endColumn)Sets the ending column of this token. |
|
public void |
setEndLine(long endLine)Sets the ending line of this token. |
|
public void |
setStartColumn(long startColumn)Sets the starting column of this token. |
|
public void |
setStartLine(long startLine)Sets the starting line of this token. |
|
public void |
setText(String text)Sets the token text. |
|
public void |
setType(JsonTokenType type)Sets the token type. |
|
public String |
toString()Returns a debug string containing the token text, type, and source positions. |
Returns the ending column of this token.
Returns the ending line of this token.
Returns the starting column of this token.
Returns the starting line of this token.
Returns the token text.
Returns the token type.
Return the value represented by this token (i.e. a number, a string, a boolean or null). For numbers, BigDecimal is returned for decimals and Integer, Long or BigInteger for integral numbers.
Sets the ending column of this token.
endColumn - the ending column numberSets the ending line of this token.
endLine - the ending line numberSets the starting column of this token.
startColumn - the starting column numberSets the starting line of this token.
startLine - the starting line numberSets the token text.
text - the token textSets the token type.
type - the token typeReturns a debug string containing the token text, type, and source positions.