/** * Export to XHTML * * @return SpecificTemplateExporterBuilderService * @throws JRException JRException exception */ public SpecificTemplateExporterBuilderService toXhtml() throws JRException { HtmlExporter htmlExporter = new HtmlExporter(); htmlExporter.setExporterInput(new SimpleExporterInput(this.report)); htmlExporter.setExporterOutput(new SimpleHtmlExporterOutput(new File(getTemplatePath().replace(extensionPattern, "html")))); htmlExporter.exportReport(); return this; }
HtmlExporter jrExporter = new HtmlExporter(); jrExporter.setExporterOutput(exporterOutput); jrExporter.setConfiguration(reportExportConfiguration); jrExporter.setConfiguration(exporterConfiguration); return jrExporter;
@SuppressWarnings("rawtypes") public Exporter setup() { return new HtmlExporter(); }
@SuppressWarnings("rawtypes") public Exporter setup() { return new HtmlExporter(); }
public static void exportReportHtml(JasperPrint jp, String path) throws JRException, FileNotFoundException { HtmlExporter exporter = new HtmlExporter(); File outputFile = new File(path); File parentFile = outputFile.getParentFile(); if (parentFile != null) parentFile.mkdirs(); FileOutputStream fos = new FileOutputStream(outputFile); SimpleExporterInput simpleExporterInput = new SimpleExporterInput(jp); SimpleHtmlExporterOutput simpleOutputStreamExporterOutput = new SimpleHtmlExporterOutput(fos); exporter.setExporterInput(simpleExporterInput); exporter.setExporterOutput(simpleOutputStreamExporterOutput); SimpleHtmlExporterConfiguration configuration = new SimpleHtmlExporterConfiguration(); exporter.setConfiguration(configuration); exporter.exportReport(); logger.debug("HTML Report exported: " + path); }
exportReport(new HtmlExporter(), jp, os);
HtmlExporter exporterHTML = new HtmlExporter(); exporterHTML.setExporterInput(exporterInput); exporterHTML.setExporterOutput(simpleHtmlExporterOutput); exporterHTML.exportReport();
exporter.setConfiguration(new SimplePdfExporterConfiguration()); } else if (ReportOutputType.html == outputType) { exporter = new HtmlExporter(); exporter.setExporterOutput(new SimpleHtmlExporterOutput(outputStream)); exporter.setConfiguration(new SimpleHtmlExporterConfiguration());
exporter.setConfiguration(new SimplePdfExporterConfiguration()); } else if (ReportOutputType.html == outputType) { exporter = new HtmlExporter(); exporter.setExporterOutput(new SimpleHtmlExporterOutput(outputStream)); exporter.setConfiguration(new SimpleHtmlExporterConfiguration());