8283698: Refactor Locale constructors used in src/test

Reviewed-by: iris, joehw
This commit is contained in:
Naoto Sato 2022-04-08 15:23:25 +00:00
parent 61698bd137
commit d6b4693c05
182 changed files with 747 additions and 747 deletions

View file

@ -74,7 +74,7 @@ import java.util.stream.Collectors;
*
* <blockquote><pre>
* NumberFormat fmt = NumberFormat.getCompactNumberInstance(
* new Locale("hi", "IN"), NumberFormat.Style.SHORT);
* Locale.forLanguageTag("hi-IN"), NumberFormat.Style.SHORT);
* String result = fmt.format(1000);
* </pre></blockquote>
*

View file

@ -2438,7 +2438,7 @@ public abstract class ResourceBundle {
* import static java.util.ResourceBundle.Control.*;
* ...
* ResourceBundle bundle =
* ResourceBundle.getBundle("MyResources", new Locale("fr", "CH"),
* ResourceBundle.getBundle("MyResources", Locale.forLanguageTag("fr-CH"),
* ResourceBundle.Control.getControl(FORMAT_PROPERTIES));
* </pre>
*