Class UserUpdateEvent

java.lang.Object
discord4j.core.event.domain.Event
discord4j.core.event.domain.UserUpdateEvent

public class UserUpdateEvent extends Event
Dispatched when the bot's user is updated. PresenceUpdateEvent is dispatched for users the bot is receiving.

This event is dispatched by Discord.

See Also:
  • Constructor Details

  • Method Details

    • getCurrent

      public User getCurrent()
      Gets the current, new version of the User that has been updated in this event.
      Returns:
      The current version of the User updated in this event.
    • getOld

      public Optional<User> getOld()
      Gets the old version of the User that has been updated in this event, if present. This may not be available if Users are not stored.
      Returns:
      The old version of the User that has been updated in this event, if present.
    • toString

      public String toString()
      Overrides:
      toString in class Object