java.lang.Object
java.lang.Enum<OS>
org.matwoess.jsourceprofiler.common.OS
All Implemented Interfaces:
Serializable, Comparable<OS>, Constable

public enum OS extends Enum<OS>
Helper enum class for operating system dependent get actions.
  • Enum Constant Details

    • WINDOWS

      public static final OS WINDOWS
    • LINUX

      public static final OS LINUX
    • MAC

      public static final OS MAC
    • SOLARIS

      public static final OS SOLARIS
  • Method Details

    • values

      public static OS[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static OS valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null
    • lineSeparator

      public String lineSeparator()
      Returns the operating system's default line separator characters.
      Returns:
      the operating system's default line separator characters
    • pathSeparator

      public String pathSeparator()
      Returns the operating system's default class path separator character.
      Returns:
      the operating system's default class path separator character
    • getOS

      public static OS getOS()
      Use the system property os.name to determine the current operating system.
      Returns:
      the enum value associated to the system that the program is run on