Enum CPU

    • Enum Constant Detail

      • unknown32

        public static final CPU unknown32
        An unknown 32-bit little-endian CPU.
      • unknown32be

        public static final CPU unknown32be
        An unknown 32-bit big-endian CPU.
      • unknown64

        public static final CPU unknown64
        An unknown 64-bit little-endian CPU.
      • unknown64be

        public static final CPU unknown64be
        An unknown 64-bit big-endian CPU.
      • x64

        public static final CPU x64
      • x86

        public static final CPU x86
      • aarch64

        public static final CPU aarch64
      • arm

        public static final CPU arm
      • riscv

        public static final CPU riscv
      • ppc32

        public static final CPU ppc32
      • ppc32le

        public static final CPU ppc32le
      • ppc

        public static final CPU ppc
      • ppcle

        public static final CPU ppcle
      • wasm32

        public static final CPU wasm32
      • mips

        public static final CPU mips
      • mipsel

        public static final CPU mipsel
      • mips64

        public static final CPU mips64
      • mips64el

        public static final CPU mips64el
    • Field Detail

      • values

        public static final List<CPU> values
        All of the possible CPU values, in order.
    • Method Detail

      • values

        public static CPU[] values()
        Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
        for (CPU c : CPU.values())
            System.out.println(c);
        
        Returns:
        an array containing the constants of this enum type, in the order they are declared
      • valueOf

        public static CPU 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
      • pointerSizeBytes

        public int pointerSizeBytes()
        Returns:
        this CPU's pointer size, in bytes
      • pointerSizeBits

        public int pointerSizeBits()
        Returns:
        this CPU's pointer size, in bits
      • nativeByteOrder

        public ByteOrder nativeByteOrder()
        Returns:
        this CPU's native byte order
      • aliases

        public Set<String> aliases()
        Returns:
        other names that this CPU is known by
      • isUnknown

        public boolean isUnknown()
        Returns:
        true if this CPU is unknown
      • forNameOrNull

        public static CPU forNameOrNull​(String name)
                                 throws NoSuchElementException
        Names are compared case-insensitively.
        Parameters:
        name - a String for the CPU name
        Returns:
        the CPU for the given name or null if it is not found
        Throws:
        NoSuchElementException
      • host

        public static CPU host()
        Returns:
        the host CPU type