为什么下一代Windows不叫Windows 9

阅读更多
http://cr.openjdk.java.net/~simonis/webrevs/8024854.v3/test/java/lang/ProcessBuilder/Basic.java.sdiff.html

static class UnicodeOS {
public static boolean is() { return is; }
private static final String osName = System.getProperty("os.name");
private static final boolean is =
    // MacOS X would probably also qualify
    osName.startsWith("Windows")   &&
    ! osName.startsWith("Windows 9") && // win95 win98
    ! osName.equals("Windows Me");
}


因为之前的代码是这样判断操作系统的,囧!

作者:翁志艺

你可能感兴趣的:(java,翁志艺)