Class Environment

java.lang.Object
org.openjdk.jmc.common.util.Environment

public class Environment extends Object
Class that returns information about the OS and other things related to the local environment
  • Constructor Details

    • Environment

      public Environment()
  • Method Details

    • isDebug

      public static boolean isDebug()
      Tell if this Mission Control instance is in debug mode, i.e. was started up with the debug flag -Dmcdebug=true.
      Returns:
      true if in debug mode
    • getFullOSName

      public static String getFullOSName()
      Returns:
      the full OS name found from the system property "os.name"
    • getOSType

      public static Environment.OSType getOSType()
      Returns:
      the OS type
    • getNormalDPI

      public static double getNormalDPI()
      Returns:
      the "normal" 100% scaled DPI setting of the OS, 96 for Windows/Linux and 72 for MacOS.
    • getThisPID

      public static int getThisPID()
      Returns:
      the PID of this JVM, or 0 if no PID could be determined