parseInt/parseLong/parseShort/parseByte/parseFloat should be preferred, as they return primitives. While valueOf returns boxed object.
------------- Commit messages: - [PATCH] Cleanup redundant boxing in java.desktop module Changes: https://git.openjdk.java.net/jdk/pull/5313/files Webrev: https://webrevs.openjdk.java.net/?repo=jdk&pr=5313&range=00 Issue: https://bugs.openjdk.java.net/browse/JDK-8273168 Stats: 18 lines in 7 files changed: 0 ins; 1 del; 17 mod Patch: https://git.openjdk.java.net/jdk/pull/5313.diff Fetch: git fetch https://git.openjdk.java.net/jdk pull/5313/head:pull/5313 PR: https://git.openjdk.java.net/jdk/pull/5313