public class ReactionAddEvent extends MessageEvent
guildId
may not be present if the message was in a private channel.
This event is dispatched by Discord.
Constructor and Description |
---|
ReactionAddEvent(DiscordClient client,
long userId,
long channelId,
long messageId,
Long guildId,
ReactionEmoji emoji) |
Modifier and Type | Method and Description |
---|---|
Mono<MessageChannel> |
getChannel()
Requests to retrieve the
MessageChannel the Message and reaction are in. |
Snowflake |
getChannelId()
|
ReactionEmoji |
getEmoji()
Gets the
ReactionEmoji that was added to the Message in this event. |
Mono<Guild> |
getGuild()
|
Optional<Snowflake> |
getGuildId()
|
Mono<Message> |
getMessage()
Request to retrieve the
Message the reaction was added to in this event. |
Snowflake |
getMessageId()
|
Mono<User> |
getUser()
Requests to retrieve the
User who added a reaction in this event. |
Snowflake |
getUserId()
|
String |
toString() |
public ReactionAddEvent(DiscordClient client, long userId, long channelId, long messageId, @Nullable Long guildId, ReactionEmoji emoji)
public Mono<User> getUser()
User
who added a reaction in this event.public Snowflake getChannelId()
MessageChannel
involved.public Mono<MessageChannel> getChannel()
MessageChannel
the Message
and reaction are in.Mono
where, upon successful completion, emits the MessageChannel
containing
the Message
in the event. If an error is received, it is emitted through the Mono
.public Snowflake getMessageId()
Message
the reaction was added to.public Mono<Message> getMessage()
Message
the reaction was added to in this event.public Optional<Snowflake> getGuildId()
Snowflake
ID of the Guild
containing the Message
and Reaction, if present.
This may not be available if the reaction is to a Message
in a private channel.Guild
involved in the event, if present.public ReactionEmoji getEmoji()
ReactionEmoji
that was added to the Message
in this event.Emoji
added to the Message
as a reaction.