Class: Discorb::Gateway::ReactionRemoveEmojiEvent
- Inherits:
 - 
      GatewayEvent
      
        
- Object
 - GatewayEvent
 - Discorb::Gateway::ReactionRemoveEmojiEvent
 
 
- Defined in:
 - lib/discorb/gateway.rb
 
Overview
Represents a MESSAGE_REACTION_REMOVE_EMOJI event.
Instance Attribute Summary collapse
- #channel -> nil, Discorb::Channel readonly
 - 
  
    
      #channel_id -> Discorb::Snowflake 
    
    
  
  
  
  
    
      readonly
    
    
  
  
  
  
  
  
    
The ID of the channel the message was sent in.
 - 
  
    
      #emoji -> Discorb::UnicodeEmoji, Discorb::PartialEmoji 
    
    
  
  
  
  
    
      readonly
    
    
  
  
  
  
  
  
    
The emoji that was reacted with.
 - #guild -> nil, Discorb::Guild readonly
 - 
  
    
      #guild_id -> Discorb::Snowflake 
    
    
  
  
  
  
    
      readonly
    
    
  
  
  
  
  
  
    
The ID of the guild the message was sent in.
 - #message -> nil, Discorb::Message readonly
 - 
  
    
      #message_id -> Discorb::Snowflake 
    
    
  
  
  
  
    
      readonly
    
    
  
  
  
  
  
  
    
The ID of the message.
 
Instance Method Summary collapse
- 
  
    
      #fetch_message(force: false) -> Async::Task<Discorb::Message> 
    
    
  
  
  
  
  
  
  
  
  
    
Fetch the message.
 
Methods inherited from GatewayEvent
Instance Attribute Details
#channel -> nil, Discorb::Channel (readonly)
    Note:
    
  
  This method returns an object from client cache. it will return nil if the object is not in cache.
      229 230 231  | 
    
      # File 'lib/discorb/gateway.rb', line 229 def channel @channel end  | 
  
#channel_id -> Discorb::Snowflake (readonly)
Returns The ID of the channel the message was sent in.
      222 223 224  | 
    
      # File 'lib/discorb/gateway.rb', line 222 def channel_id @channel_id end  | 
  
#emoji -> Discorb::UnicodeEmoji, Discorb::PartialEmoji (readonly)
Returns The emoji that was reacted with.
      237 238 239  | 
    
      # File 'lib/discorb/gateway.rb', line 237 def emoji @emoji end  | 
  
#guild -> nil, Discorb::Guild (readonly)
    Note:
    
  
  This method returns an object from client cache. it will return nil if the object is not in cache.
      232 233 234  | 
    
      # File 'lib/discorb/gateway.rb', line 232 def guild @guild end  | 
  
#guild_id -> Discorb::Snowflake (readonly)
Returns The ID of the guild the message was sent in.
      226 227 228  | 
    
      # File 'lib/discorb/gateway.rb', line 226 def guild_id @guild_id end  | 
  
#message -> nil, Discorb::Message (readonly)
    Note:
    
  
  This method returns an object from client cache. it will return nil if the object is not in cache.
      235 236 237  | 
    
      # File 'lib/discorb/gateway.rb', line 235 def @message end  | 
  
#message_id -> Discorb::Snowflake (readonly)
Returns The ID of the message.
      224 225 226  | 
    
      # File 'lib/discorb/gateway.rb', line 224 def @message_id end  | 
  
Instance Method Details
#fetch_message(force: false) -> Async::Task<Discorb::Message>
Fetch the message. If message is cached, it will be returned.
      265 266 267 268 269 270 271  | 
    
      # File 'lib/discorb/gateway.rb', line 265 def (force: false) Async do next @message if !force && @message @message = @channel.(@message_id).wait end end  |