/* (non-Javadoc)
* @see org.eclipse.core.internal.jobs.InternalJob#run(org.eclipse.core.runtime.IProgressMonitor)
*/
protected IStatus run(IProgressMonitor monitor) {
TreeNode root = new TreeNode("");
File it = new File(proj.getLocation().addTrailingSeparator() + "goblin.xml");
if (! it.canRead())
return new Status(IStatus.ERROR, "ee.ut.goblin", 97, "Can't read analysis file.", null);
DefaultHandler handler = new XMLHandler(root);
SAXParserFactory factory = SAXParserFactory.newInstance();
try {
// Parse the input
SAXParser saxParser = factory.newSAXParser();
saxParser.parse(it, handler);
} catch (Throwable t) {
return new Status(IStatus.ERROR, "ee.ut.goblin", 96, t.getMessage(), t);
}
TreeAnalysisMap tam = new TreeAnalysisMap((TreeAnalysis) root.getChildren()[0]);
try {
proj.setSessionProperty(GoblinPlugin.RESULT_NAME, tam);
} catch (CoreException e) {
return new Status(IStatus.ERROR, "ee.ut.goblin", 95, e.getMessage(), e);