Token class

Token used while parsing SGF text.

  • type: Kind of token.
  • value: Raw matched lexeme (for example ;, AB, [aa]).
  • row, col: 0-based line and column in the input.
  • pos: Offset from the start of the input in UTF-16 code units.
  • progress: Normalized progress across the input (0.0–1.0).

Equality and hashCode use all fields.

Constructors

Token(TokenType type, String value, int row, int col, int pos, double progress)
const

Properties

col int
final
hashCode int
The hash code for this object.
no setteroverride
pos int
final
progress double
final
row int
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
type TokenType
final
value String
final

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
override