Package ghidra.framework

# Enum Class Platform

java.lang.Object
java.lang.Enum<Platform>
ghidra.framework.Platform

All Implemented Interfaces:
  `Serializable`, `Comparable<Platform>`, `Constable`

public enum Platform extends Enum<Platform>
Identifies the current platform (operating system and architecture) and identifies the appropriate module OS directory which contains native binaries

- ## Nested Class Summary

  ## Nested classes/interfaces inherited from class java.lang.Enum

  `Enum.EnumDesc<E extends Enum<E>>`

- ## Enum Constant Summary

  Enum Constants
  Enum Constant
  Description
  `LINUX`
  Deprecated, for removal: This API element is subject to removal in a future version.
  Use `LINUX_X86_32` instead.
  `LINUX_64`
  Deprecated, for removal: This API element is subject to removal in a future version.
  Use `LINUX_X86_64` instead.
  `LINUX_ARM_64`
  Identifies a Linux ARM 64-bit OS.
  `LINUX_UKNOWN`
  Deprecated, for removal: This API element is subject to removal in a future version.
  Unknown architectures are not supported
  `LINUX_X86_32`
  Identifies a Linux x86 32-bit OS.
  `LINUX_X86_64`
  Identifies a Linux x86 64-bit OS.
  `MAC_ARM_64`
  Identifies a macOS ARM 64-bit OS.
  `MAC_OSX_32`
  Deprecated, for removal: This API element is subject to removal in a future version.
  Use `MAC_OSX_32` instead.
  `MAC_OSX_64`
  Deprecated, for removal: This API element is subject to removal in a future version.
  Use `MAC_X86_64` instead.
  `MAC_UNKNOWN`
  Deprecated, for removal: This API element is subject to removal in a future version.
  Use `MAC_X86_64` instead.
  `MAC_X86_32`
  Identifies a macOS x86 32-bit OS.
  `MAC_X86_64`
  Identifies a macOS x86 64-bit OS.
  `UNSUPPORTED`
  Identifies an unsupported OS.
  `WIN_64`
  Deprecated, for removal: This API element is subject to removal in a future version.
  Use `WIN_X86_64` instead.
  `WIN_UNKOWN`
  Deprecated, for removal: This API element is subject to removal in a future version.
  Unknown architectures are not supported
  `WIN_X86_32`
  Identifies a Windows x86 32-bit OS.
  `WIN_X86_64`
  Identifies a Windows x86 64-bit OS.

- ## Field Summary

  Fields
  Modifier and Type
  Field
  Description
  `static final Platform`
  `CURRENT_PLATFORM`
  A constant identifying the current platform.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `List<String>`
  `getAdditionalLibraryPaths()`
  Based on the current platform, returns an operating system specific library paths that are not found on the PATH environment variable.
  `Architecture`
  `getArchitecture()`
  Returns the architecture for this platform.
  `String`
  `getDirectoryName()`
  Returns the directory name of the current platform.
  `String`
  `getExecutableExtension()`
  `String`
  `getLibraryExtension()`
  Returns the library extension for this platform.
  `OperatingSystem`
  `getOperatingSystem()`
  Returns the operating system for this platform.
  `String`
  `toString()`
  `static Platform`
  `valueOf(String name)`
  Returns the enum constant of this class with the specified name.
  `static Platform[]`
  `values()`
  Returns an array containing the constants of this enum class, in the order they are declared.

  ### Methods inherited from class java.lang.Enum

  `clone, compareTo, describeConstable, equals, finalize, getDeclaringClass, hashCode, name, ordinal, valueOf`

  ### Methods inherited from class java.lang.Object

  `getClass, notify, notifyAll, wait, wait, wait`

- ## Enum Constant Details

  - ### WIN_X86_32

    public static final Platform WIN_X86_32
    Identifies a Windows x86 32-bit OS.

  - ### WIN_X86_64

    public static final Platform WIN_X86_64
    Identifies a Windows x86 64-bit OS.

  - ### LINUX_X86_32

    public static final Platform LINUX_X86_32
    Identifies a Linux x86 32-bit OS.

  - ### LINUX_X86_64

    public static final Platform LINUX_X86_64
    Identifies a Linux x86 64-bit OS.

  - ### LINUX_ARM_64

    public static final Platform LINUX_ARM_64
    Identifies a Linux ARM 64-bit OS.

  - ### MAC_X86_32

    public static final Platform MAC_X86_32
    Identifies a macOS x86 32-bit OS.

  - ### MAC_X86_64

    public static final Platform MAC_X86_64
    Identifies a macOS x86 64-bit OS.

  - ### MAC_ARM_64

    public static final Platform MAC_ARM_64
    Identifies a macOS ARM 64-bit OS.

  - ### UNSUPPORTED

    public static final Platform UNSUPPORTED
    Identifies an unsupported OS.

  - ### WIN_64

    @Deprecated(since="10.1", forRemoval=true) public static final Platform WIN_64
    Deprecated, for removal: This API element is subject to removal in a future version.
    Use `WIN_X86_64` instead.
    Identifies a Windows 64-bit OS.

  - ### WIN_UNKOWN

    @Deprecated(since="10.1", forRemoval=true) public static final Platform WIN_UNKOWN
    Deprecated, for removal: This API element is subject to removal in a future version.
    Unknown architectures are not supported
    Identifies a Windows OS, the architecture for which we do not know or have not encountered. We'll treat it as `WIN_X86_64` and hope for the best.

  - ### LINUX

    @Deprecated(since="10.1", forRemoval=true) public static final Platform LINUX
    Deprecated, for removal: This API element is subject to removal in a future version.
    Use `LINUX_X86_32` instead.
    Identifies a Linux X86 32-bit OS.

  - ### LINUX_64

    @Deprecated(since="10.1", forRemoval=true) public static final Platform LINUX_64
    Deprecated, for removal: This API element is subject to removal in a future version.
    Use `LINUX_X86_64` instead.
    Identifies a Linux X86 64-bit OS.

  - ### LINUX_UKNOWN

    @Deprecated(since="10.1", forRemoval=true) public static final Platform LINUX_UKNOWN
    Deprecated, for removal: This API element is subject to removal in a future version.
    Unknown architectures are not supported
    Identifies a Linux OS, the architecture for which we do not know or have not encountered. We'll treat it as `LINUX_X86_64` and hope for the best.

  - ### MAC_OSX_32

    @Deprecated(since="10.1", forRemoval=true) public static final Platform MAC_OSX_32
    Deprecated, for removal: This API element is subject to removal in a future version.
    Use `MAC_OSX_32` instead.
    Identifies a macOS X86 32-bit OS.

  - ### MAC_OSX_64

    @Deprecated(since="10.1", forRemoval=true) public static final Platform MAC_OSX_64
    Deprecated, for removal: This API element is subject to removal in a future version.
    Use `MAC_X86_64` instead.
    Identifies a macOS X86 64-bit OS.

  - ### MAC_UNKNOWN

    @Deprecated(since="10.1", forRemoval=true) public static final Platform MAC_UNKNOWN
    Deprecated, for removal: This API element is subject to removal in a future version.
    Use `MAC_X86_64` instead.
    Identifies a macOS OS, the architecture for which we do not know or have not encountered. We'll treat it as `MAC_X86_64` and hope for the best.

- ## Field Details

  - ### CURRENT_PLATFORM

    public static final Platform CURRENT_PLATFORM
    A constant identifying the current platform.

- ## Method Details

  - ### values

    public static Platform[] 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 Platform 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

  - ### getOperatingSystem

    public OperatingSystem getOperatingSystem()
    Returns the operating system for this platform.
    Returns:
      the operating system for this platform

  - ### getArchitecture

    public Architecture getArchitecture()
    Returns the architecture for this platform.
    Returns:
      the architecture for this platform

  - ### getDirectoryName

    public String getDirectoryName()
    Returns the directory name of the current platform.
    Returns:
      the directory name of the current platform

  - ### getLibraryExtension

    public String getLibraryExtension()
    Returns the library extension for this platform.
    Returns:
      the library extension for this platform

  - ### getAdditionalLibraryPaths

    public List<String> getAdditionalLibraryPaths()
    Based on the current platform, returns an operating system specific library paths that are not found on the PATH environment variable.
    Returns:
      additional library paths

  - ### toString

    public String toString()
    Overrides:
      `toString` in class `Enum<Platform>`

  - ### getExecutableExtension

    public String getExecutableExtension()