|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.prorefactor.treeparser.ParseUnit
public class ParseUnit
Provides parse unit information, such as the symbol table and a reference to the AST. TreeParser01 calls symbolUsage() in this class in order to build the symbol table.
Field Summary | |
---|---|
static int |
CONNECTED
The JPNode tree is "connected" to Proparse, by default |
static int |
DEFAULT
The JPNode tree is "connected" to Proparse, by default |
static int |
DISCONNECTED
Working with JPNode in disconnected mode may not yet be fully supported. |
protected java.io.File |
file
|
protected PUB |
pub
|
protected RefactorSession |
refpack
|
protected int |
style
|
Constructor Summary | |
---|---|
ParseUnit(java.io.File file)
|
Method Summary | |
---|---|
java.io.File |
getFile()
|
java.lang.String[] |
getFileIndex()
Get the file index, either from the PUB file or from the parser, whichever was used to get the tree. |
IncludeRef |
getMacroGraph()
This will trigger a parse if the PUB is out of date. |
MacroRef[] |
getMacroSourceArray()
This is just a shortcut for calling getMacroGraph() and MacroLevel.sourceArray(). |
PUB |
getPUB()
Get or create a PUB |
SymbolScopeRoot |
getRootScope()
|
ProgramRootNode |
getTopNode()
Get the syntax tree top (Program_root) node |
void |
loadOrBuildPUB()
Load from PUB, or build PUB if it's out of date. |
void |
parse()
|
ParseUnit |
setPUB(PUB pub)
|
void |
setRootScope(SymbolScopeRoot rootScope)
|
void |
setTopNode(JPNode topNode)
Set the syntax tree top (Program_root) node. |
void |
treeParser(IJPTreeParser tp)
Run any IJPTreeParser against the AST. |
void |
treeParser01()
Run TreeParser01. |
void |
treeParser01(TP01Action action)
Run TreeParser01 with any TP01Action object. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final int CONNECTED
public static final int DEFAULT
public static final int DISCONNECTED
protected int style
protected java.io.File file
protected PUB pub
protected RefactorSession refpack
Constructor Detail |
---|
public ParseUnit(java.io.File file)
Method Detail |
---|
public java.io.File getFile()
public java.lang.String[] getFileIndex()
JPNode.getFilenames()
public IncludeRef getMacroGraph() throws RefactorException, java.io.IOException
RefactorException
java.io.IOException
public MacroRef[] getMacroSourceArray() throws RefactorException, java.io.IOException
RefactorException
java.io.IOException
MacroLevel.sourceArray(MacroRef)
public PUB getPUB()
public SymbolScopeRoot getRootScope()
public ProgramRootNode getTopNode()
public void loadOrBuildPUB() throws RefactorException, java.io.IOException
RefactorException
java.io.IOException
public void parse() throws RefactorException
RefactorException
public ParseUnit setPUB(PUB pub)
public void setRootScope(SymbolScopeRoot rootScope)
public void setTopNode(JPNode topNode)
public void treeParser(IJPTreeParser tp) throws RefactorException
RefactorException
public void treeParser01() throws RefactorException
RefactorException
public void treeParser01(TP01Action action) throws RefactorException
RefactorException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |