Class OS


  • public class OS
    extends Object
    Provides methods related to the runtime environment.
    • Constructor Detail

      • OS

        public OS()
    • Method Detail

      • isMacOSX

        public static boolean isMacOSX()
        Returns:
        true if this VM is running on Mac OS X
      • isWindows

        public static boolean isWindows()
        Returns:
        true if this VM is running on Windows
      • isWindowsXP

        public static boolean isWindowsXP()
        Returns:
        true if this VM is running on Windows XP
      • isWindows2003

        public static boolean isWindows2003()
        Returns:
        true if this VM is running on Windows 2003
      • isWindowsVista

        public static boolean isWindowsVista()
        Returns:
        true if this VM is running on Windows Vista
      • isLinux

        public static boolean isLinux()
        Returns:
        true if this VM is running on a Linux distribution
      • isUsingWindowsVisualStyles

        public static boolean isUsingWindowsVisualStyles()
        Returns:
        true if the VM is running Windows and the Java application is rendered using XP Visual Styles.
      • getWindowsVisualStyle

        public static String getWindowsVisualStyle()
        Returns the name of the current Windows visual style.
        Returns:
        the name of the current Windows visual style if any.