Skip to content

Package io.github.qishr.cascara.lang.yaml.token

Class YamlToken

java.lang.Object
        io.github.qishr.cascara.lang.yaml.token.YamlToken

All Implemented Interfaces:
    Token

Direct Known Subtypes:
    YamlErrorToken


public class YamlToken

Constructor Summary

Constructor Description
YamlToken(int line, int column, int startOffset, YamlTokenType type) Structural Token
YamlToken(int line, int column, int startOffset, YamlTokenType type, String content)
YamlToken(int line, int column, int startOffset, YamlTokenType type, String lexeme, String content, ScalarStyle scalarStyle, int firstLineIndent, int blockIndent)

Method Summary

Modifier and Type Method Description
public int getStartLine()
public int getStartColumn()
public int getOffset()
public int getFirstLineIndent()
public int getBlockIndent()
public YamlTokenType getType()
public String getLexeme()
public String getContent()
public ScalarStyle getScalarStyle()
public boolean startsOnNewLine()
public YamlToken setStartsOnNewLine(boolean b)
public boolean isFollowedByTab()
public YamlToken setFollowedByTab(boolean b)
public boolean hasPreceedingNewLine()
public YamlToken setHasPreceedingNewLine(boolean b)
public YamlToken setType(YamlTokenType type)
public String toString()

Method Details

getStartLine

public int getStartLine()

Specified By:

Token


getStartColumn

public int getStartColumn()

Specified By:

Token


getOffset

public int getOffset()

Specified By:

Token


getFirstLineIndent

public int getFirstLineIndent()


getBlockIndent

public int getBlockIndent()


getType

public YamlTokenType getType()

Specified By:

Token


getLexeme

public String getLexeme()

Specified By:

Token


getContent

public String getContent()

Specified By:

Token


getScalarStyle

public ScalarStyle getScalarStyle()


startsOnNewLine

public boolean startsOnNewLine()


setStartsOnNewLine

public YamlToken setStartsOnNewLine(boolean b)


isFollowedByTab

public boolean isFollowedByTab()


setFollowedByTab

public YamlToken setFollowedByTab(boolean b)


hasPreceedingNewLine

public boolean hasPreceedingNewLine()


setHasPreceedingNewLine

public YamlToken setHasPreceedingNewLine(boolean b)


setType

public YamlToken setType(YamlTokenType type)


toString

public String toString()

Specified By:

Token

Overrides:

Object