Enum SlashCommandPermissionType

    • Method Detail

      • values

        public static SlashCommandPermissionType[] 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 (SlashCommandPermissionType c : SlashCommandPermissionType.values())
            System.out.println(c);
        
        Returns:
        an array containing the constants of this enum type, in the order they are declared
      • valueOf

        public static SlashCommandPermissionType 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
      • getValue

        public int getValue​()
        Gets integer value that represents this type.
        Returns:
        The integer value that represents this type.
      • fromValue

        public static SlashCommandPermissionType fromValue​(int value)
        Gets an SlashCommandPermissionType by its value.
        Parameters:
        value - The value of the slash command permission type.
        Returns:
        The slash command permission type for the given value, or UNKNOWN if there's none with the given value.