Class: SpotifAye::Artist
Instance Attribute Summary collapse
-
#href ⇒ Object
Returns the value of attribute href.
-
#name ⇒ Object
Returns the value of attribute name.
-
#popularity ⇒ Object
Returns the value of attribute popularity.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(result) ⇒ Artist
constructor
A new instance of Artist.
Constructor Details
#initialize(result) ⇒ Artist
Returns a new instance of Artist.
13 14 15 16 17 |
# File 'lib/spotif-aye.rb', line 13 def initialize(result) self.name = result['name'] self.href = result['href'] self.popularity = result['popularity'].to_f end |
Instance Attribute Details
#href ⇒ Object
Returns the value of attribute href.
11 12 13 |
# File 'lib/spotif-aye.rb', line 11 def href @href end |
#name ⇒ Object
Returns the value of attribute name.
11 12 13 |
# File 'lib/spotif-aye.rb', line 11 def name @name end |
#popularity ⇒ Object
Returns the value of attribute popularity.
11 12 13 |
# File 'lib/spotif-aye.rb', line 11 def popularity @popularity end |