Class MessageUpdateEvent
- java.lang.Object
-
- net.dv8tion.jda.core.events.Event
-
- net.dv8tion.jda.core.events.message.GenericMessageEvent
-
- net.dv8tion.jda.core.events.message.MessageUpdateEvent
-
public class MessageUpdateEvent extends GenericMessageEvent
Indicates that a Message was edited in aMessageChannel
.Can be used to detect a Message is edited in either a private or guild channel. Providing a MessageChannel and Message.
This also includes whether a message is being pinned.JDA does not have a cache for messages and is not able to provide previous information due to limitations by the Discord API!
-
-
Constructor Summary
Constructors Constructor Description MessageUpdateEvent(JDA api, long responseNumber, Message message)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description User
getAuthor()
The author of the Message.Member
getMember()
Member instance for the author of this message ornull
if this was not in a Guild.Message
getMessage()
TheMessage
that was updated
Note: Messages in JDA are not updated, they are immutable and will not change their state.-
Methods inherited from class net.dv8tion.jda.core.events.message.GenericMessageEvent
getChannel, getChannelType, getGroup, getGuild, getMessageId, getMessageIdLong, getPrivateChannel, getTextChannel, isFromType
-
Methods inherited from class net.dv8tion.jda.core.events.Event
getJDA, getResponseNumber
-
-
-
-
Method Detail
-
getMessage
public Message getMessage()
TheMessage
that was updated
Note: Messages in JDA are not updated, they are immutable and will not change their state.- Returns:
- The updated Message
-
getAuthor
public User getAuthor()
The author of the Message.- Returns:
- The message author
- See Also:
User
-
getMember
public Member getMember()
Member instance for the author of this message ornull
if this was not in a Guild.- Returns:
- The Member instance for the author or null
-
-