Class DefaultReaction

java.lang.Object
discord4j.core.object.reaction.DefaultReaction
All Implemented Interfaces:
DiscordObject

public final class DefaultReaction extends Object implements DiscordObject
DefaultReaction is used by ForumChannel as an emoji shown as a quick reaction button on the thread in a forum channel. When selecting an emoji, the user can use it from the forum channel page.
  • Constructor Details

    • DefaultReaction

      public DefaultReaction(GatewayDiscordClient gateway, discord4j.discordjson.json.DefaultReactionData data)
  • Method Details

    • getClient

      public GatewayDiscordClient getClient()
      Description copied from interface: DiscordObject
      Returns the GatewayDiscordClient that created this object. Methods in it are exclusively based on the entity cache or Store in use. Refer to calling getClient().rest() to access a DiscordClient that is capable of requesting entities directly from the REST API.
      Specified by:
      getClient in interface DiscordObject
      Returns:
      The GatewayDiscordClient associated to this object.
    • getEmojiId

      public Optional<Snowflake> getEmojiId()
      Gets the emoji id if this tag is represented as a custom guild emoji At least this field or getEmojiName() is present and filled.
      Returns:
      An Optional which may contain a custom guild emoji id.
    • getEmojiName

      public Optional<String> getEmojiName()
      Gets the unicode emoji if this tag is represented as a unicode emoji At least this field or getEmojiId() is present and filled.
      Returns:
      An Optional which may contain a custom guild emoji id.
    • getData

      public discord4j.discordjson.json.DefaultReactionData getData()
      Gets the DefaultReactionData associated to this wrapper
      Returns:
      the DefaultReactionData object wrapped by this object