Class: Discogs::Contributor

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

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(name, role) ⇒ Contributor

Returns a new instance of Contributor.



4
5
6
7
# File 'lib/contributor.rb', line 4

def initialize(name, role)
  @name = name
  @role = role
end

Instance Attribute Details

#nameObject

Returns the value of attribute name.



3
4
5
# File 'lib/contributor.rb', line 3

def name
  @name
end

#roleObject

Returns the value of attribute role.



3
4
5
# File 'lib/contributor.rb', line 3

def role
  @role
end

Instance Method Details

#to_sObject

:nodoc:



9
10
11
# File 'lib/contributor.rb', line 9

def to_s #:nodoc:
  "#{name} as #{role}"
end