diff options
author | Daniel Schwarz <daniel.schwarz@sonarsource.com> | 2017-10-10 18:10:28 +0200 |
---|---|---|
committer | Daniel Schwarz <bartfastiel@users.noreply.github.com> | 2017-10-10 18:49:34 +0200 |
commit | f363643318a80a0d1b9799eff0a7b0156d9a5708 (patch) | |
tree | 8cc08085c0080ccbb976abf9e65c1429bb901f11 /server/sonar-process/src | |
parent | 1af027a26a4c694428beea69e3351cb1d0fb95b0 (diff) | |
download | sonarqube-f363643318a80a0d1b9799eff0a7b0156d9a5708.tar.gz sonarqube-f363643318a80a0d1b9799eff0a7b0156d9a5708.zip |
fix quality flaws
Diffstat (limited to 'server/sonar-process/src')
-rw-r--r-- | server/sonar-process/src/main/java/org/sonar/process/System2.java | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/server/sonar-process/src/main/java/org/sonar/process/System2.java b/server/sonar-process/src/main/java/org/sonar/process/System2.java index 1c9ca5c51c6..0e32165046c 100644 --- a/server/sonar-process/src/main/java/org/sonar/process/System2.java +++ b/server/sonar-process/src/main/java/org/sonar/process/System2.java @@ -20,6 +20,7 @@ package org.sonar.process; import java.util.Map; +import org.apache.commons.lang.SystemUtils; /** * An interface allowing to wrap around static call to {@link System} class. @@ -35,6 +36,11 @@ public interface System2 { public String getenv(String name) { return System.getenv(name); } + + @Override + public boolean isOsWindows() { + return SystemUtils.IS_OS_WINDOWS; + } }; /** @@ -46,4 +52,9 @@ public interface System2 { * Proxy to {@link System#getenv(String)}. */ String getenv(String name); + + /** + * True if this is MS Windows. + */ + boolean isOsWindows(); } |