abhishek24509 / aribaweb

Automatically exported from code.google.com/p/aribaweb
Apache License 2.0
0 stars 0 forks source link

Some DataTable samples throw exceptions when run under non-US locale #16

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
The "SimpleTable" sample will throw the following exception when run under some 
non-US 
locales (e.g. French):
  groovy.lang.MissingMethodException:
  No signature of method: java.lang.String.intValue() is applicable for argument types: () values: []

Analysis:
The demo data CSV parser, AWTCSVDataSource, is attempting to use a number 
parser in the 
*current* locale instead of one in the "canonical locale" (US) used by the 
sample data CSV files.

Patch:
In widgets/ariba/ui/table/AWTCSVDataSource.java, change:
    static NumberFormat _NumberFormatter = NumberFormat.getNumberInstance(Locale.US);
to
    static NumberFormat _NumberFormatter = NumberFormat.getNumberInstance(Locale.US);

Original issue reported on code.google.com by Ariba...@gmail.com on 24 Feb 2009 at 5:09

GoogleCodeExporter commented 8 years ago

Original comment by Ariba...@gmail.com on 24 Feb 2009 at 5:10

GoogleCodeExporter commented 8 years ago
Patch should read:
Change: 
Patch:
In widgets/ariba/ui/table/AWTCSVDataSource.java, change:
    static NumberFormat _NumberFormatter = NumberFormat.getNumberInstance();
to
    static NumberFormat _NumberFormatter = NumberFormat.getNumberInstance(Locale.US);

Original comment by Ariba...@gmail.com on 24 Feb 2009 at 5:11

GoogleCodeExporter commented 8 years ago
http://code.google.com/p/aribaweb/source/detail?spec=svn16&r=16

Original comment by kingsley...@gmail.com on 4 May 2009 at 10:07