|
|||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||
java.lang.Object | +--exp.Parser
Parser Classe astratta per un generico analizzatore sintattico
| Field Summary | |
protected Sexp |
curToken
Token corente |
protected Lexer |
lex
Analizzatore lessicale (fornisce i token) |
protected OutputDevice |
msgOut
Dispositivo di output |
| Constructor Summary | |
Parser(Lexer lex)
Costruttore |
|
Parser(Lexer lex,
OutputDevice msgOut)
Costruttore |
|
| Method Summary | |
boolean |
atEOF()
Indicazione di fine file |
protected void |
nextToken()
Consumo del token corrente e avanzamento al successivo |
Sexp |
parse()
Lettura della prossima Sexp |
void |
print(java.lang.String s)
Scrittura di un messaggio in output |
void |
println(java.lang.String s)
Scrittura di un messaggio in output con ritorno a capo |
protected abstract Sexp |
readSexp()
Lettura di un'espressione |
| Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
| Field Detail |
protected Sexp curToken
protected Lexer lex
protected OutputDevice msgOut
| Constructor Detail |
public Parser(Lexer lex,
OutputDevice msgOut)
throws java.lang.Exception
public Parser(Lexer lex)
throws java.lang.Exception
| Method Detail |
public void print(java.lang.String s)
public void println(java.lang.String s)
public boolean atEOF()
public Sexp parse()
throws java.lang.Exception
protected void nextToken()
throws java.lang.Exception
protected abstract Sexp readSexp()
throws java.lang.Exception
|
|||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||