class Discorb::Role::Tag
Represents a tag of a role.
Attributes
bot_id[R]
@return [Discorb::Snowflake] The ID of the bot that owns the role.
integration_id[R]
@return [Discorb::Snowflake] The ID of the integration.
Public Class Methods
new(data)
click to toggle source
@!visibility private
# File lib/discorb/role.rb, line 158 def initialize(data) @bot_id = Snowflake.new(data[:bot_id]) @integration_id = Snowflake.new(data[:integration_id]) @premium_subscriber = data.key?(:premium_subscriber) end
Public Instance Methods
bot?()
click to toggle source
# File lib/discorb/role.rb, line 164 def bot? !@bot_id.nil? end
integration?()
click to toggle source
# File lib/discorb/role.rb, line 168 def integration? !@integration_id.nil? end