Class: Discordrb::Member
- Includes:
- MemberAttributes, PermissionCalculator
- Defined in:
- lib/discordrb/data.rb
Overview
A member is a user on a server. It differs from regular users in that it has roles, voice statuses and things like that.
Instance Attribute Summary
Attributes included from MemberAttributes
#deaf, #joined_at, #mute, #roles, #server, #voice_channel
Attributes inherited from User
Attributes included from UserAttributes
#avatar_id, #bot_account, #discriminator, #username
Attributes included from IDObject
Instance Method Summary collapse
-
#inspect ⇒ Object
Overwriting inspect for debug purposes.
-
#owner? ⇒ true, false
Whether this member is the server owner.
Methods included from PermissionCalculator
#defined_permission?, #permission?
Methods inherited from User
#await, #current_bot?, #on, #pm
Methods included from UserAttributes
#avatar_url, #distinct, #mention
Methods included from IDObject
Instance Method Details
#inspect ⇒ Object
Overwriting inspect for debug purposes
364 365 366 |
# File 'lib/discordrb/data.rb', line 364 def inspect "<Member user=#{@user.inspect} server=#{@server.inspect} joined_at=#{@joined_at} roles=#{@roles.inspect} voice_channel=#{@voice_channel.inspect} mute=#{@mute} deaf=#{@deaf} self_mute=#{@self_mute} self_deaf=#{@self_deaf}>" end |
#owner? ⇒ true, false
337 338 339 |
# File 'lib/discordrb/data.rb', line 337 def owner? @server.owner == self end |