8271456: Avoid looking up standard charsets in "java.desktop" module #4951
This is a request to clean up a desktop module as was done in JDK-8233884 for "java.base" module.
In many places standard charsets are looked up via their names, for example:
This could be done more efficiently(x20 time faster) with use of java.nio.charset.StandardCharsets:
The later variant also makes the code cleaner, as it is known not to throw UnsupportedEncodingException in contrary to the former variant.
Tested by the desktop headless/headful tests on linux/windows.
The text was updated successfully, but these errors were encountered:
@mrserb This change now passes all automated pre-integration checks.
After integration, the commit message for the final commit will be:
At the time when this comment was updated there had been 23 new commits pushed to the
As there are no conflicts, your changes will automatically be rebased on top of these commits when integrating. If you prefer to avoid this automatic rebasing, please check the documentation for the /integrate command for further details.
Going to push as commit 6b55ef3.
Your commit was automatically rebased without conflicts.