Package eu.bandm.tscore.base
Class Lexer
java.lang.Object
eu.bandm.tscore.base.Lexer
Definition for the basic tokenization of tscore input.
The fundamental "raw" layer makes only rough separation of
input-text components---the semantic oriented parsing happens in
later processing steps.
Assume that the input is free of chars < 0x20, except \n, \t,
and \f, as e.g. guaranteed by
LocationCodePointSource
.-
Nested Class Summary
Nested Classes -
Method Summary
Modifier and TypeMethodDescriptionstatic <D> TokenSource
<D, Lexer.TokenType> tokenSource
(Reader reader, D sourceIndication) Constructs a TokenSource which parses the Reader according to the static lexer rules in this class.
-
Method Details
-
tokenSource
Constructs a TokenSource which parses the Reader according to the static lexer rules in this class. No token types are discarded, but all are propagated to the consumer. Error message locations are calculated based onLocation.EMACS_FIRST_LINE_NUMBER
andLocation.EMACS_FIRST_COLUMN_NUMBER
. No explicit messaging of input stream errors, but one token withinvalid reference
TokenType.ERROR
-