Token class

A produced token: its rule type, the matched value, and the start offset into the original input.

Annotations

Constructors

Token(String type, String value, int start)
Creates a token of type holding value, found at start. Audited: 2026-06-12 11:26 EDT
const

Properties

hashCode int
The hash code for this object.
no setteroverride
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
start int
The 0-based offset of value in the original input.
final
type String
The label from the TokenRule that produced this token.
final
value String
The exact matched substring.
final

Methods

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

Operators

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