Class: Caldera::Events::WebSocketClosed

Inherits:
Object
  • Object
show all
Defined in:
lib/caldera/events.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(data, _player) ⇒ WebSocketClosed

Returns a new instance of WebSocketClosed.



61
62
63
64
65
66
# File 'lib/caldera/events.rb', line 61

def initialize(data, _player)
  @guild_id = data['guildId']
  @code = data['code']
  @reason = data['reason']
  @by_remote = data['byRemote']
end

Instance Attribute Details

#by_remoteObject (readonly) Also known as: by_remote?

Returns the value of attribute by_remote.



58
59
60
# File 'lib/caldera/events.rb', line 58

def by_remote
  @by_remote
end

#codeObject (readonly)

Returns the value of attribute code.



52
53
54
# File 'lib/caldera/events.rb', line 52

def code
  @code
end

#guild_idObject (readonly)

Returns the value of attribute guild_id.



49
50
51
# File 'lib/caldera/events.rb', line 49

def guild_id
  @guild_id
end

#reasonObject (readonly)

Returns the value of attribute reason.



55
56
57
# File 'lib/caldera/events.rb', line 55

def reason
  @reason
end