@Override public void finish() { bugCollection.bugsPopulated(); if (writer != null) { writer.flush(); } }
/** * Write the BugCollection to given output stream as XML. The output stream * will be closed, even if an exception is thrown. * * @param out * the OutputStream to write to */ @Override public void writeXML(@WillClose Writer out) throws IOException { assert project != null; bugsPopulated(); XMLOutput xmlOutput; // if (project == null) throw new NullPointerException("No project"); xmlOutput = new OutputStreamXMLOutput(out); writeXML(xmlOutput); }
@Override public void finish() { bugCollection.bugsPopulated(); if (writer != null) { writer.flush(); } }
/** * Write the BugCollection to given output stream as XML. The output stream * will be closed, even if an exception is thrown. * * @param out * the OutputStream to write to */ @Override public void writeXML(@WillClose Writer out) throws IOException { assert project != null; bugsPopulated(); XMLOutput xmlOutput; // if (project == null) throw new NullPointerException("No project"); if (withMessages && cloud != null) { cloud.bugsPopulated(); cloud.initiateCommunication(); cloud.waitUntilIssueDataDownloaded(); String token = SystemProperties.getProperty("findbugs.cloud.token"); if (token != null && token.trim().length() > 0) { LOGGER.info("Cloud token specified - uploading new issues, if necessary..."); cloud.waitUntilNewIssuesUploaded(); } xmlOutput = new OutputStreamXMLOutput(out, "http://findbugs.sourceforge.net/xsl/default.xsl"); } else { xmlOutput = new OutputStreamXMLOutput(out); } writeXML(xmlOutput); }