ExpressionNumberState

Implements an Expression-specific number state object.

Extends: GenericNumberState

Description

The ExpressionNumberState implements an expression-specific number state object.

Fields

PLUS

Represents a ‘+’ symbol.

PLUS: int = ‘+'.codeUnitAt(0)

EXP1

Represents an ‘e’ symbol.

EXP1: int = ‘e’.codeUnitAt(0)

EXP2

Represents an ‘E’ symbol.

EXP2: int = ‘E’.codeUnitAt(0)

Instance methods

nextToken

Gets the next token from the stream, starting from the character linked to this state.

@override

Token? nextToken(IScanner scanner, ITokenizer? tokenizer)

  • scanner: IScanner - textual string to be tokenized.
  • tokenizer: ITokenizer? - tokenizer class that controls the process.
  • returns: Token? - next token from the top of the stream.