|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.croftsoft.apps.compiler.mini.parse.MiniScanner
public class MiniScanner
Token scanner for the Mini programming language. Reference:
"JLex: A Lexical Analyzer Generator for Java"
http://www.cs.princeton.edu/~appel/modern/java/JLex/
Field Summary |
---|
Fields inherited from interface com.croftsoft.apps.compiler.mini.parse.MiniSymbols |
---|
$START, ASSIGN, assignmentStatement, BEGIN, block, CALL, COMMA, comparison, conditionalStatement, CONSTANT, declaration, declarationSequence, definiteLoop, DIVIDE, DO, element, ELSE, END, EOF, EQ, error, EXP, expression, expressionList, FI, GE, GT, IF, indefiniteLoop, inputStatement, INTEGER, LE, LPAREN, LT, MINUS, MOD, NAME, name1, nameList, NE, outputStatement, parameterList, PLUS, PROCEDURE, procedureCall, program, READ, relation, RPAREN, SEMICOLON, statement, statementSequence, strongOperator, term, THEN, TIMES, TO, UMINUS, weakOperator, WHILE, WRITE |
Constructor Summary | |
---|---|
MiniScanner(InputStream instream)
|
|
MiniScanner(Reader reader)
|
Method Summary | |
---|---|
static void |
main(String[] args)
|
Symbol |
nextToken()
|
static Symbol |
scanConstant(String text)
|
static void |
test(Reader reader)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public MiniScanner(Reader reader)
public MiniScanner(InputStream instream)
Method Detail |
---|
public static void main(String[] args) throws Exception
Exception
public static void test(Reader reader) throws Exception
Exception
public static Symbol scanConstant(String text)
public Symbol nextToken() throws IOException
nextToken
in interface CUPTokenScanner
IOException
|
CroftSoft Javadoc | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |