ByteArrayOutputStream out = new ByteArrayOutputStream( 8096 ); stats.reportSummary( out ); transformSummary( out.toString() ); out.close();
StringWriter html = new StringWriter(); try { stats.transformSummaryToHTML(html); summary = html.toString(); } catch (Exception e) { logger.logMessage(ConsoleLogger.WARNING,  "Failed to transform summary: " + e.toString()); summary = MISSING_SUMMARY_MESSAGE; }
    private void createSummary(ProjectStats stats) throws IOException {        ByteArrayOutputStream out = new ByteArrayOutputStream( 8096 );	stats.reportSummary( out );        transformSummary( out.toString() );        out.close();    }