I created some reports through TIBCO Jaspersoft® Studio - Visual Designer for JasperReports
and I'm using the lib below in my project.
<dependency>
<groupId>net.sf.jasperreports</groupId>
<artifactId>jasperreports</artifactId>
<version>6.0.0</version>
</dependency>
In previous versions I was using JRXlsExporter
but some methods are obsolete and I did not find the new form in the official documentation (or I did not know how to look or it really was not updated).
Example:
JRXlsExporter exporter = new JRXlsExporter();
response.setHeader("Content-Disposition", "attachment; filename=PONTOS_DE_VENDA.xls");
response.setContentType("Content-type: application/vnd.ms-excel"); //DEPRECATED
exporter.setParameter(JExcelApiExporterParameter.JASPER_PRINT, jasperPrint); //DEPRECATED
exporter.setParameter(JExcelApiExporterParameter.OUTPUT_STREAM, response.getOutputStream()); //DEPRECATED
Has anyone used this new version yet? Or where I find some example of usage.