(I am basing my question on this HARDCODED example from April 2016 and am seeking an updated, dynamic answer since the "bug" has been fixed - not having the locale available in the Customizer)
/* -Hardcoded example */
getNumberInstance(Locale.US)); //"Locale.US" is hardcoded rather than using the locale set in the report
Goal: Pass Locale set in jasper reports to chart and read with chart Customizer.
- How do I properly read the Report Locale now that the bug of it not being available has been fixed (see here)?
Problem: In the Customizer Class (written in Java) this command does not contain anything: JRParameter.REPORT_LOCALE.
public class AssetsChartMod implements JRChartCustomizer {
public void customize(JFreeChart chart, JRChart jasperChart) {
/* ----> */
System.out.println( JRParameter.REPORT_LOCALE ); // PRINTS NOTHING