Enum EmbedType

java.lang.Object
java.lang.Enum<EmbedType>
net.dv8tion.jda.api.entities.EmbedType
All Implemented Interfaces:
Serializable, Comparable<EmbedType>

public enum EmbedType extends Enum<EmbedType>
Represents the embedded resource type.
These are typically either Images, Videos or Links.
  • Enum Constant Details

    • IMAGE

      public static final EmbedType IMAGE
    • VIDEO

      public static final EmbedType VIDEO
    • RICH

      public static final EmbedType RICH
    • AUTO_MODERATION

      public static final EmbedType AUTO_MODERATION
    • UNKNOWN

      public static final EmbedType UNKNOWN
  • Method Details

    • values

      public static EmbedType[] 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 EmbedType 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
    • fromKey

      @Nonnull public static EmbedType fromKey(String key)
      Attempts to find the EmbedType from the provided key.
      If the provided key doesn't match any known EmbedType, this will return UNKNOWN.
      Parameters:
      key - The key related to the EmbedType.
      Returns:
      The EmbedType matching the provided key, or UNKNOWN.