mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-27 23:04:50 +02:00
8310201: Reduce verbose locale output in -XshowSettings launcher option
Reviewed-by: jpai
This commit is contained in:
parent
a4412166ec
commit
f6e23ae451
2 changed files with 22 additions and 7 deletions
|
@ -170,7 +170,7 @@ public final class LauncherHelper {
|
|||
printProperties();
|
||||
break;
|
||||
case "locale":
|
||||
printLocale();
|
||||
printLocale(false);
|
||||
break;
|
||||
case "security":
|
||||
var opt = opts.length > 2 ? opts[2].trim() : "all";
|
||||
|
@ -184,7 +184,7 @@ public final class LauncherHelper {
|
|||
default:
|
||||
printVmSettings(initialHeapSize, maxHeapSize, stackSize);
|
||||
printProperties();
|
||||
printLocale();
|
||||
printLocale(true);
|
||||
SecuritySettings.printSecuritySummarySettings(ostream);
|
||||
if (OperatingSystem.isLinux()) {
|
||||
printSystemMetrics();
|
||||
|
@ -280,9 +280,15 @@ public final class LauncherHelper {
|
|||
/*
|
||||
* prints the locale subopt/section
|
||||
*/
|
||||
private static void printLocale() {
|
||||
private static void printLocale(boolean summaryMode) {
|
||||
Locale locale = Locale.getDefault();
|
||||
ostream.println(LOCALE_SETTINGS);
|
||||
if (!summaryMode) {
|
||||
ostream.println(LOCALE_SETTINGS);
|
||||
} else {
|
||||
ostream.println("Locale settings summary:");
|
||||
ostream.println(INDENT + "Use \"-XshowSettings:locale\" " +
|
||||
"option for verbose locale settings options");
|
||||
}
|
||||
ostream.println(INDENT + "default locale = " +
|
||||
locale.getDisplayName());
|
||||
ostream.println(INDENT + "default display locale = " +
|
||||
|
@ -291,7 +297,9 @@ public final class LauncherHelper {
|
|||
Locale.getDefault(Category.FORMAT).getDisplayName());
|
||||
ostream.println(INDENT + "tzdata version = " +
|
||||
ZoneInfoFile.getVersion());
|
||||
printLocales();
|
||||
if (!summaryMode) {
|
||||
printLocales();
|
||||
}
|
||||
ostream.println();
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue