Class RoleDeleteEvent


  • public class RoleDeleteEvent
    extends RoleEvent
    Dispatched when a role is deleted in a guild.

    The deleted role may not be present if roles are not stored.

    This event is dispatched by Discord.

    See Also:
    Guild Role Delete
    • Method Detail

      • getGuild

        public Mono<Guild> getGuild()
        Requests to retrieve the Guild the Role was deleted in.
        Returns:
        A Mono where, upon successful completion, emits the Guild containing the deleted Role. If an error is received, it is emitted through the Mono.
      • getRoleId

        public Snowflake getRoleId()
        Gets the Snowflake ID of the Role that was deleted in this event.
        Returns:
        The ID of the deleted Role.
      • getRole

        public Optional<Role> getRole()
        Gets the Role that was deleted in this event, if present. This may not be available if Roles are not stored.
        Returns:
        The Role that was deleted in this event, if present.