class Discorb::AuditLog::Integration

Represents an integration in an audit log entry.

Attributes

account[R]

@return [Discorb::Integration::Account] The account of the integration.

id[R]

@return [Discorb::Snowflake] The ID of the integration.

name[R]

@return [String] The name of the integration.

type[R]

@return [Symbol] The type of the integration.

Public Class Methods

new(data) click to toggle source

@!visibility private

# File lib/discorb/audit_logs.rb, line 313
def initialize(data)
  @id = Snowflake.new(data[:id])
  @type = data[:type].to_sym
  @name = data[:name]
  @data = data
  @account = Discorb::Integration::Account.new(@data[:account]) if @data[:account]
end

Public Instance Methods

inspect() click to toggle source
# File lib/discorb/audit_logs.rb, line 321
def inspect
  "#<#{self.class} #{@id}>"
end