Class SystemProperties

java.lang.Object
com.intellij.util.SystemProperties

public class SystemProperties extends Object
Utility wrappers for accessing system properties.
  • Method Details

    • getUserHome

      public static String getUserHome()
    • getUserName

      public static String getUserName()
    • setTestUserName

      @TestOnly public static void setTestUserName(@Nullable String name)
    • getLineSeparator

      public static String getLineSeparator()
    • getOsName

      public static String getOsName()
    • getJavaVersion

      public static String getJavaVersion()
      If you need to compare Java version with some value, use SystemInfo.isJavaVersionAtLeast(String).
    • getJavaVmVendor

      public static String getJavaVmVendor()
    • getJavaHome

      public static String getJavaHome()
    • getIntProperty

      public static int getIntProperty(@NotNull String key, int defaultValue)
      Returns the value of given property as integer, or defaultValue if the property is not specified or malformed.
    • getBooleanProperty

      public static boolean getBooleanProperty(@NotNull String key, boolean defaultValue)
      Returns the value of given property as a boolean, or defaultValue if the property is not specified or malformed.
    • getJavaVendor

      public static String getJavaVendor()
    • is

      public static boolean is(String key)
    • has

      public static boolean has(String key)