Enum EnumPlatform

java.lang.Object
java.lang.Enum<EnumPlatform>
me.friwi.jcefmaven.EnumPlatform
All Implemented Interfaces:
Serializable, Comparable<EnumPlatform>, java.lang.constant.Constable

public enum EnumPlatform extends Enum<EnumPlatform>
Enum representing all supported operating system and architecture combinations. Fetch the currently applying platform using getCurrentPlatform(). Use getOs() to extract the operating system only.
Author:
Fritz Windisch
  • Enum Constant Details

    • MACOSX_AMD64

      public static final EnumPlatform MACOSX_AMD64
    • MACOSX_ARM64

      public static final EnumPlatform MACOSX_ARM64
    • LINUX_AMD64

      public static final EnumPlatform LINUX_AMD64
    • LINUX_ARM64

      public static final EnumPlatform LINUX_ARM64
    • LINUX_ARM

      public static final EnumPlatform LINUX_ARM
    • WINDOWS_AMD64

      public static final EnumPlatform WINDOWS_AMD64
    • WINDOWS_I386

      public static final EnumPlatform WINDOWS_I386
    • WINDOWS_ARM64

      public static final EnumPlatform WINDOWS_ARM64
  • Field Details

  • Method Details

    • values

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

      public static EnumPlatform valueOf(String name)
      Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (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 type has no constant with the specified name
      NullPointerException - if the argument is null
    • getCurrentPlatform

      public static EnumPlatform getCurrentPlatform() throws UnsupportedPlatformException
      Fetches the platform this program is running on.
      Returns:
      the current platform
      Throws:
      UnsupportedPlatformException - if the platform could not be determined
    • getIdentifier

      public String getIdentifier()
      Method used internally to fetch the identifier used in jcefbuild.
      Returns:
      the platform identifier, a lower case string in the format of os-arch (e.g. linux-amd64)
    • getOs

      public EnumOS getOs()
      Fetch the operating system of this platform
      Returns:
      the os