Package ca.phon.util

Class OSInfo

java.lang.Object
ca.phon.util.OSInfo

public class OSInfo extends Object
Utility class for determining host OS.
  • Field Details

    • OS_TYPE

      public static final OSInfo.OSType OS_TYPE
      Field containing the host OS type
  • Constructor Details

    • OSInfo

      public OSInfo()
  • Method Details

    • getOSType

      public static OSInfo.OSType getOSType()
      Get the host os type.
      Returns:
      the host os type, or OSType.OTHER is not detected
    • isMacOs

      public static boolean isMacOs()
      Is the host os Mac OS?
      Returns:
      true if system property 'mrj.version' is set false otherwise.
    • isWindows

      public static boolean isWindows()
      Is the host os windows?
      Returns:
      true if system property 'os.name' contains the string 'windows', false otherwise
    • isNix

      public static boolean isNix()
      Is the host os *nix?
      Returns:
      true if system property 'os.name' contains the string 'nix' or 'nux', false otherwise