Package com.axelor.report
Class ReportGenerator
java.lang.Object
com.axelor.report.ReportGenerator
The report generator service.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
Generate a report for the given report design.void
generate
(OutputStream output, String designName, String format, Map<String, Object> params, Locale locale) Generate a report for the given report design.Generate a report to a temporary file and return path to the generated file.Generate a report to a temporary file and return path to the generated file.
-
Constructor Details
-
ReportGenerator
public ReportGenerator()
-
-
Method Details
-
generate
public void generate(OutputStream output, String designName, String format, Map<String, Object> params) throws IOException, org.eclipse.birt.core.exception.BirtExceptionGenerate a report for the given report design.- Parameters:
output
- the report output streamdesignName
- report designformat
- output format (e.g. pdf, html etc)params
- report parameters- Throws:
IOException
- if an I/O exception occursorg.eclipse.birt.core.exception.BirtException
- if rendering fails
-
generate
public void generate(OutputStream output, String designName, String format, Map<String, Object> params, Locale locale) throws IOException, org.eclipse.birt.core.exception.BirtExceptionGenerate a report for the given report design.- Parameters:
output
- the report output streamdesignName
- report designformat
- output format (e.g. pdf, html etc)params
- report parameterslocale
- report output locale- Throws:
IOException
- if an I/O exception occursorg.eclipse.birt.core.exception.BirtException
- if rendering fails
-
generate
public File generate(String designName, String format, Map<String, Object> params) throws IOException, org.eclipse.birt.core.exception.BirtExceptionGenerate a report to a temporary file and return path to the generated file.- Parameters:
designName
- report design nameformat
- output formatparams
- report parameters- Returns:
Path
to the generated file- Throws:
IOException
- if an I/O exception occursorg.eclipse.birt.core.exception.BirtException
- if rendering fails
-
generate
public File generate(String designName, String format, Map<String, Object> params, Locale locale) throws IOException, org.eclipse.birt.core.exception.BirtExceptionGenerate a report to a temporary file and return path to the generated file.- Parameters:
designName
- report design nameformat
- output formatparams
- report parameterslocale
- report output language- Returns:
Path
to the generated file- Throws:
IOException
- if an I/O exception occursorg.eclipse.birt.core.exception.BirtException
- if rendering fails
-