/** * Read XML data from given file into this object, populating given Project * as a side effect. * * @param file * the file */ public void readXML(File file) throws IOException, DocumentException { project.setCurrentWorkingDirectory(file.getParentFile()); dataSource = file.getAbsolutePath(); InputStream in = progessMonitoredInputStream(file, "Loading analysis"); try { readXML(in, file); } catch (IOException e) { throw newIOException(file, e); } catch (DocumentException e) { throw new DocumentException("Failing reading " + file, e); } }
/** * Read XML data from given file into this object, populating given Project * as a side effect. * * @param file * the file */ public void readXML(File file) throws IOException, DocumentException { project.setCurrentWorkingDirectory(file.getParentFile()); dataSource = file.getAbsolutePath(); InputStream in = progessMonitoredInputStream(file, "Loading analysis"); try { readXML(in, file); } catch (IOException e) { throw newIOException(file, e); } catch (DocumentException e) { throw new DocumentException("Failing reading " + file, e); } }
findbugsProject.addAuxClasspathEntry(jsr305Lib.getCanonicalPath()); findbugsProject.setCurrentWorkingDirectory(fileSystem.workDir()); return findbugsProject;
@Override public void run() { mainFrame.acquireDisplayWait(); try { Project project = new Project(); project.setGuiCallback(mainFrame.getGuiCallback()); project.setCurrentWorkingDirectory(file.getParentFile()); BugLoader.loadBugs(mainFrame, project, file); project.getSourceFinder(); // force source finder to be // initialized mainFrame.updateBugTree(); } finally { mainFrame.releaseDisplayWait(); } } };