Class BasicLexicalAnalyzer

java.lang.Object
com.scriptbasic.lexer.BasicLexicalAnalyzer
All Implemented Interfaces:
LexicalAnalyzer, LineOrientedLexicalAnalyzer
Direct Known Subclasses:
ScriptBasicLexicalAnalyzer

public class BasicLexicalAnalyzer
extends java.lang.Object
implements LineOrientedLexicalAnalyzer
  • Constructor Summary

    Constructors 
    Constructor Description
    BasicLexicalAnalyzer​(SourceReader reader)  
  • Method Summary

    Modifier and Type Method Description
    LexicalElement get()
    Get the next lexical element from the input stream.
    LexicalElement peek()
    Peek at the next lexical element and do not remove it from the input stream.
    void registerElementAnalyzer​(LexicalElementAnalyzer lea)
    Register a lexical element analyzer.
    void resetLine()
    Resets the state of the lexical analyzer so that the internal lexeme pointer is reset to the first lexeme of the actual line and the next call to LexicalAnalyzer.get() will return again the first lexeme of the line.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait