The Version table provides details related to the release that this issue/RFE will be addressed.
Unresolved : Release in which this issue/RFE will be addressed. Resolved: Release in which this issue/RFE has been resolved. Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.
The description should include API or property descriptions and references to the APIs as appropriate.
Comments
Updated the JEP description.
17-11-2016
Draft:
Summary
-------
Define a means for applications to specify property files encoded in UTF-8, and extend the
`ResourceBundle` API to load them.
Motivation
----------
The platform has for a long time provided a properties-file format that
is based on ISO-8859-1 and provides an escape mechanism for characters
that cannot be represented in that encoding. This format is supported by
the standard resource-bundle lookup mechanism. As noted in the related
RFEs, this format is difficult to use because it requires continuous
conversion between its escaped form and text in character encodings that
are directly editable.
Description
-----------
By changing the file encoding of the properties files from ISO-8859-1 to UTF-8, applications no longer need to convert the properties files using the escape mechanism. Existing properties files are ra
rely affected by this change, since ISO-8859-1's U+0000-U+007F are compatible with UTF-8, and charac
ters whose code points are over U+00FF should have been escaped.
If an exception occurs, either MalformedInputException or UnmappableCharacterException, the properti
es file is read from the beginning, reverting to using ISO-8859-1 encoding. In order for a rare occation where a ISO-8859-1 properties file can be recognized as a valid UTF-8 file, this JEP provides a mean to explicity specify the encoding either ISO-8859-1 or UTF-8, by setting the system property "java.util.PropertyResourceBundle.encoding".