* Scans the outline and builds a hierarchy tree
* @param doc Document used to start deriving the hierarchy
* @return true if the scan is successful, false otherwise
*/
public boolean scanOutline(HdlDocument doc){
OutlineDatabase database;
Vector<ArchitectureElement> archList;
OutlineElement[] topLevelElements;
Set<String> entityNameList;
Vector<String> topLevelEntities=new Vector<String>();
String entityName;
m_TopLevelEntities.clear();
m_EntityArchList.clear();
m_ElementDeclList.clear();
try {
database = (OutlineDatabase)
doc.getProject().getSessionProperty(VerilogPlugin.getOutlineDatabaseId());
} catch (CoreException e) {
e.printStackTrace();
return false;
}
////////////////////////////////////////////
//scan for architectures
topLevelElements = database.findTopLevelElements("");
for (int i=0;i<topLevelElements.length;i++){
//architectures
if (topLevelElements[i] instanceof ArchitectureElement) {
ArchitectureElement arch = (ArchitectureElement) topLevelElements[i];
String archEntityName=arch.GetEntityName().toUpperCase();