DEFAULT_ENCODING_NAME in URLEncoder and URLDecoder can be replaced with Charset.defaultCharset(), which removes unnecessary static fields and avoid looking up charset when calling URLDecoder.decode(String) and URLEncoder.encode(String).
Since Charset.defaultCharset() is also initialized with StaticProperty.fileEncoding(), this causes no change in behavior.
The javadoc of URLDecoder.decode(String) and URLEncoder.encode(String) say that they use the default charset, so this change is semantically consistent with the documentation.
Since Charset.defaultCharset() is also initialized with StaticProperty.fileEncoding(), this causes no change in behavior.
The javadoc of URLDecoder.decode(String) and URLEncoder.encode(String) say that they use the default charset, so this change is semantically consistent with the documentation.