I\'m writing a pretty simple sample project for familiarizing myself with Jasper Reports. I\'d like to export a report I\'ve configured to a PDF OutputStream, b
JRExporterParameter is deprecated in latest versions, This is a non deprecated solution of @stevemac answer
JRPdfExporter exporter = new JRPdfExporter();
exporter.setExporterInput(new SimpleExporterInput(jasperPrint));
exporter.setExporterOutput(new SimpleOutputStreamExporterOutput(outputStream));
SimplePdfExporterConfiguration configuration = new SimplePdfExporterConfiguration();
configuration.setMetadataAuthor("Petter"); //why not set some config as we like
exporter.setConfiguration(configuration);
exporter.exportReport();