Package foundry.veil.impl.glsl
Class GlslTokenReader
java.lang.Object
foundry.veil.impl.glsl.GlslTokenReader
-
Nested Class Summary
Nested Classes -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleancanConsume(GlslLexer.TokenType token) booleancanRead()booleancanRead(int length) consume(GlslLexer.TokenType token) intintgetCursorOffset(int cursor) voidpeek()peek(int amount) peekType(int amount) voidsetCursor(int cursor) voidskip()voidskip(int amount) voidtoString()booleantryConsume(GlslLexer.TokenType... tokens)
-
Constructor Details
-
GlslTokenReader
-
-
Method Details
-
getCursorOffset
public int getCursorOffset(int cursor) -
getString
-
canRead
public boolean canRead(int length) -
canRead
public boolean canRead() -
peek
-
peek
-
peekType
-
canConsume
-
consume
- Throws:
GlslSyntaxException
-
tryConsume
-
error
-
throwError
- Throws:
GlslSyntaxException
-
skip
public void skip() -
skip
public void skip(int amount) -
markError
-
getErrors
- Returns:
- All errors marked from reading tokens
-
getCursor
public int getCursor() -
setCursor
public void setCursor(int cursor) -
toString
-