From 16c3a3297597214f7b1478db5799325ea114df88 Mon Sep 17 00:00:00 2001 From: "Gary D. Gregory" Date: Fri, 7 Oct 2011 20:12:48 +0000 Subject: [PATCH] [LANG-759] Add Support in SystemUtils for Windows Server 2003 and Windows Server 2008. git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1180197 13f79535-47bb-0310-9956-ffa450edef68 --- .../org/apache/commons/lang3/SystemUtils.java | 24 +++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/src/main/java/org/apache/commons/lang3/SystemUtils.java b/src/main/java/org/apache/commons/lang3/SystemUtils.java index b65bb1e6d..bb43eca41 100644 --- a/src/main/java/org/apache/commons/lang3/SystemUtils.java +++ b/src/main/java/org/apache/commons/lang3/SystemUtils.java @@ -1110,6 +1110,30 @@ public class SystemUtils { */ public static final boolean IS_OS_WINDOWS_2000 = getOSMatches(OS_NAME_WINDOWS_PREFIX, "5.0"); + /** + *

+ * Is {@code true} if this is Windows 2003. + *

+ *

+ * The field will return {@code false} if {@code OS_NAME} is {@code null}. + *

+ * + * @since 3.1 + */ + public static final boolean IS_OS_WINDOWS_2003 = getOSMatches(OS_NAME_WINDOWS_PREFIX, "5.2"); + + /** + *

+ * Is {@code true} if this is Windows 2008. + *

+ *

+ * The field will return {@code false} if {@code OS_NAME} is {@code null}. + *

+ * + * @since 3.1 + */ + public static final boolean IS_OS_WINDOWS_2008 = getOSMatches(OS_NAME_WINDOWS_PREFIX + " Server 2008", "6.1"); + /** *

* Is {@code true} if this is Windows 95.