Class: Discorb::Role::Tag

Inherits:
DiscordModel show all
Defined in:
lib/discorb/role.rb

Overview

Represents a tag of a role.

Instance Attribute Summary collapse

Method Summary

Methods inherited from DiscordModel

#==, #eql?, #inspect

Instance Attribute Details

#bot? -> Boolean (readonly)

Returns Whether the role is a bot role.

Returns:

  • (Boolean)

    Whether the role is a bot role.



# File 'lib/discorb/role.rb', line 196

#bot_id -> Discorb::Snowflake (readonly)

Returns The ID of the bot that owns the role.

Returns:



190
191
192
# File 'lib/discorb/role.rb', line 190

def bot_id
  @bot_id
end

#integration? -> Boolean (readonly)

Returns Whether the role is an integration role.

Returns:

  • (Boolean)

    Whether the role is an integration role.



# File 'lib/discorb/role.rb', line 196

#integration_id -> Discorb::Snowflake (readonly)

Returns The ID of the integration.

Returns:



192
193
194
# File 'lib/discorb/role.rb', line 192

def integration_id
  @integration_id
end

#premium_subscriber -> Boolean (readonly) Also known as: premium_subscriber?

Returns Whether the tag is a premium subscriber role.

Returns:

  • (Boolean)

    Whether the tag is a premium subscriber role.



194
195
196
# File 'lib/discorb/role.rb', line 194

def premium_subscriber
  @premium_subscriber
end