|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Object | +--org.opencores.edifp.Parser
Parser class provides basic LL(1) parser for EDIF file
| Field Summary | |
private int |
arrayElt
element in array |
private PathScope |
curPath
current namescope |
private static boolean |
debug
Are we doing debug here? |
private static java.io.PrintWriter |
err
writter, copied from Conf.log |
private Lex |
lex
|
private int |
numArray
num elements for last object ID |
private java.lang.String |
realName
real last object name |
private PathScope |
refPath
referenced namescope |
| Constructor Summary | |
Parser(Lex lex)
constructs new parser. |
|
| Method Summary | |
private void |
_interface()
dissolves token with same name using LL(1) structure |
private void |
cell()
dissolves token with same name using LL(1) structure |
private void |
cellRef()
dissolves token with same name using LL(1) structure |
private boolean |
checkEmpty()
|
private void |
contents()
dissolves token with same name using LL(1) structure |
private void |
design()
dissolves token with same name using LL(1) structure |
private void |
dissolveRef(int level)
utility for dissolving references |
private Graph |
edif()
dissolves token with same name using LL(1) structure |
(package private) void |
error(int token)
reports token # expected |
(package private) void |
error(java.lang.String msg)
reports an error |
private void |
external()
dissolves token with same name using LL(1) structure |
private Symbol |
get(int id)
get specific token, otherwise return error |
private java.lang.String |
getID()
gets identifier |
private java.lang.String |
getID(boolean allowArrays)
gets identifier extended |
private int |
getNum()
get NUMBER |
private void |
instance()
dissolves token with same name using LL(1) structure |
private void |
instanceRef()
dissolves token with same name using LL(1) structure |
private void |
joined()
dissolves token with same name using LL(1) structure |
private void |
library()
dissolves token with same name using LL(1) structure |
private void |
libraryRef()
dissolves token with same name using LL(1) structure |
private void |
lp()
look for LPAREN |
static Graph |
main(java.lang.String infile)
parses EDIF file. |
private void |
net()
dissolves token with same name using LL(1) structure |
private void |
netRef()
dissolves token with same name using LL(1) structure |
private Symbol |
next()
get next token |
Graph |
parse()
|
private void |
port()
dissolves token with same name using LL(1) structure |
private void |
portRef()
dissolves token with same name using LL(1) structure |
private void |
property(Instance i)
dissolves token with same name using LL(1) structure |
private java.lang.String |
rename(boolean allowArray)
dissolves rename, member or array |
private void |
rp()
look for RPAREN |
private void |
skipBlock(Symbol s)
skip to last RPAREN |
private void |
view()
dissolves token with same name using LL(1) structure |
private void |
viewRef()
dissolves token with same name using LL(1) structure |
| Methods inherited from class java.lang.Object |
|
| Field Detail |
private static boolean debug
private Lex lex
private static java.io.PrintWriter err
private java.lang.String realName
private int numArray
private int arrayElt
private PathScope curPath
private PathScope refPath
| Constructor Detail |
public Parser(Lex lex)
lex - lexical analizer parser is going to be attached to| Method Detail |
public static Graph main(java.lang.String infile)
throws java.lang.Exception
infile - file to parseGraph
private Symbol next()
throws java.lang.Exception
private Symbol get(int id)
throws java.lang.Exception
private int getNum()
throws java.lang.Exception
private void lp()
throws java.lang.Exception
private void rp()
throws java.lang.Exception
private boolean checkEmpty()
throws java.lang.Exception
private void skipBlock(Symbol s)
throws java.lang.Exception
private java.lang.String getID(boolean allowArrays)
throws java.lang.Exception
private java.lang.String getID()
throws java.lang.Exception
private java.lang.String rename(boolean allowArray)
throws java.lang.Exception
void error(java.lang.String msg)
void error(int token)
public Graph parse()
throws java.lang.Exception
private Graph edif()
throws java.lang.Exception
private void library()
throws java.lang.Exception
private void external()
throws java.lang.Exception
private void cell()
throws java.lang.Exception
private void view()
throws java.lang.Exception
private void _interface()
throws java.lang.Exception
private void port()
throws java.lang.Exception
private void contents()
throws java.lang.Exception
private void instance()
throws java.lang.Exception
private void property(Instance i)
throws java.lang.Exception
private void net()
throws java.lang.Exception
private void joined()
throws java.lang.Exception
private void design()
throws java.lang.Exception
private void dissolveRef(int level)
throws java.lang.Exception
private void libraryRef()
throws java.lang.Exception
private void cellRef()
throws java.lang.Exception
private void viewRef()
throws java.lang.Exception
private void portRef()
throws java.lang.Exception
private void instanceRef()
throws java.lang.Exception
private void netRef()
throws java.lang.Exception
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||