[Java] Class JsonToken
- groovy.json.JsonToken
public class JsonToken
A JSON token, with a type, line / column information, and the text of that token.
- Since:
- 1.8.0
Methods Summary
Type Params | Return Type | Name and description |
---|---|---|
public long |
getEndColumn() | |
public long |
getEndLine() | |
public long |
getStartColumn() | |
public long |
getStartLine() | |
public String |
getText() | |
public JsonTokenType |
getType() | |
public Object |
getValue() Return the value represented by this token (ie. a number, a string, a boolean or null). | |
public void |
setEndColumn(long endColumn) | |
public void |
setEndLine(long endLine) | |
public void |
setStartColumn(long startColumn) | |
public void |
setStartLine(long startLine) | |
public void |
setText(String text) | |
public void |
setType(JsonTokenType type) | |
public String |
toString() |
Inherited Methods Summary
Methods inherited from class | Name |
---|---|
class Object | wait, wait, wait, equals, toString, hashCode, getClass, notify, notifyAll |
Method Detail
public long getEndColumn()
public long getEndLine()
public long getStartColumn()
public long getStartLine()
public String getText()
public JsonTokenType getType()
public Object getValue()
Return the value represented by this token (ie. a number, a string, a boolean or null). For numbers, BigDecimal is returned for decimals and Integer, Long or BigInteger for integral numbers.
- Returns:
- the represented value
public void setEndColumn(long endColumn)
public void setEndLine(long endLine)
public void setStartColumn(long startColumn)
public void setStartLine(long startLine)
public void setText(String text)
public void setType(JsonTokenType type)
public String toString()
© 2003-2020 The Apache Software Foundation
Licensed under the Apache license.
https://docs.groovy-lang.org/3.0.7/html/gapi/groovy/json/JsonToken.html