Package groovy.json
Class JsonToken
java.lang.Object
groovy.json.JsonToken
A JSON token, with a type, line / column information, and the text of that token.
- Since:
- 1.8.0
- Author:
- Guillaume Laforge
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionlong
long
long
long
getText()
getType()
getValue()
Return the value represented by this token (ie.void
setEndColumn
(long endColumn) void
setEndLine
(long endLine) void
setStartColumn
(long startColumn) void
setStartLine
(long startLine) void
void
setType
(JsonTokenType type) toString()
-
Constructor Details
-
JsonToken
public JsonToken()
-
-
Method Details
-
getValue
Return the value represented by this token (ie. a number, a string, a boolean or null). For numbers, the most appropriate type is returned (Float, Double, BigDecimal for decimal numbers, and Integer, Long and BigInteger for integral numbers).- Returns:
- the represented value
-
toString
-
getStartLine
public long getStartLine() -
setStartLine
public void setStartLine(long startLine) -
getEndLine
public long getEndLine() -
setEndLine
public void setEndLine(long endLine) -
getStartColumn
public long getStartColumn() -
setStartColumn
public void setStartColumn(long startColumn) -
getEndColumn
public long getEndColumn() -
setEndColumn
public void setEndColumn(long endColumn) -
getType
-
setType
-
setText
-
getText
-