[java] return friendly names for Windows platforms like Mac does
existing value of toString() is available with name()
@@ -49,6 +49,10 @@ public Platform family() {
public Platform family() {
return WINDOWS;
}
+ @Override
+ public String toString() {
+ return "Windows XP";
+ }
},
/**
@@ -59,6 +63,10 @@ public Platform family() {
public Platform family() {
return WINDOWS;
}
+ @Override
+ public String toString() {
+ return "Windows Vista";
+ }
},
/**
@@ -69,6 +77,10 @@ public Platform family() {
public Platform family() {
return WINDOWS;
}
+ @Override
+ public String toString() {
+ return "Windows 8";
+ }
},
WIN8_1("windows 8.1", "win8.1") {
@@ -76,6 +88,10 @@ public Platform family() {
public Platform family() {
return WINDOWS;
}
+ @Override
+ public String toString() {
+ return "Windows 8.1";
+ }
},
WIN10("windows 10", "win10") {
@@ -83,6 +99,10 @@ public Platform family() {
public Platform family() {
return WINDOWS;
}
+ @Override
+ public String toString() {
+ return "Windows 10";
+ }
},
WIN11("windows 11", "win11") {
@@ -90,6 +110,10 @@ public Platform family() {
public Platform family() {
return WINDOWS;
}
+ @Override
+ public String toString() {
+ return "Windows 11";
+ }
},
MAC("mac", "darwin", "macOS", "mac os x", "os x") {
