Constructor
new Token(type, text)
Constructs a token with the specified type and text
Parameters:
Name | Type | Description |
---|---|---|
type |
TokenType | The type of the token |
text |
String | The texual representation of the token |
- Source:
Methods
getText() → {String}
Gets the texual representation of the token
- Source:
Returns:
The token text
- Type
- String
getType() → {TokenType}
Gets the type of the token
- Source:
Returns:
The token type
- Type
- TokenType