Package io.github.qishr.cascara.lang.json.token
Class JsonBufferBackedToken
java.lang.Object
io.github.qishr.cascara.lang.json.token.JsonBufferBackedToken
All Implemented Interfaces:
JsonToken
public final class JsonBufferBackedToken
Field Summary
| Modifier and Type | Field | Description |
|---|---|---|
| protected final int | startColumn | |
| protected final int | startLine | |
| protected final int | startOffset | |
| protected final JsonTokenType | type |
Constructor Summary
| Constructor | Description |
|---|---|
| JsonBufferBackedToken(LexemeProvider provider, int startLine, int startColumn, int startOffset, int endOffset, JsonTokenType type) | |
| JsonBufferBackedToken(LexemeProvider provider, int startLine, int startColumn, int startOffset, int endOffset, QuoteStyle quoteStyle) |
Method Summary
| Modifier and Type | Method | Description |
|---|---|---|
| public String | getLexeme() | |
| public String | getContent() | |
| public int | getEndOffset() | |
| public JsonTokenType | getType() | |
| public JsonLiteral | getLiteral() | |
| public QuoteStyle | getQuoteStyle() | |
| public int | getOffset() | |
| public int | getStartLine() | |
| public int | getStartColumn() | |
| public List<JsonComment> | getComments() | |
| public void | attachComments(List<JsonComment> list) | |
| public String | toString() |
Field Details
startColumn
protected final int startColumn
startLine
protected final int startLine
startOffset
protected final int startOffset
type
protected final JsonTokenType type
Method Details
getLexeme
public String getLexeme()
getContent
public String getContent()
getEndOffset
public int getEndOffset()
getType
public JsonTokenType getType()
Specified By:
getLiteral
public JsonLiteral getLiteral()
Specified By:
getQuoteStyle
public QuoteStyle getQuoteStyle()
Specified By:
getOffset
public int getOffset()
getStartLine
public int getStartLine()
getStartColumn
public int getStartColumn()
getComments
public List<JsonComment> getComments()
Specified By:
attachComments
public void attachComments(List<JsonComment> list)
Specified By:
toString
public String toString()
Overrides: