Class: Spotify::Models::SavedAlbum
- Inherits:
-
Object
- Object
- Spotify::Models::SavedAlbum
- Defined in:
- lib/spotify/models/saved_album.rb
Instance Attribute Summary collapse
-
#added_at ⇒ Object
readonly
Returns the value of attribute added_at.
-
#album ⇒ Object
readonly
Returns the value of attribute album.
Instance Method Summary collapse
-
#initialize(args = {}) ⇒ SavedAlbum
constructor
A new instance of SavedAlbum.
Constructor Details
#initialize(args = {}) ⇒ SavedAlbum
Returns a new instance of SavedAlbum.
9 10 11 12 13 14 15 16 |
# File 'lib/spotify/models/saved_album.rb', line 9 def initialize(args = {}) args = args.with_indifferent_access @album = Album.new(args[:name]) # HACK: Using JSON while the other classes aren't available. @added_at = args[:added_at] end |
Instance Attribute Details
#added_at ⇒ Object (readonly)
Returns the value of attribute added_at.
7 8 9 |
# File 'lib/spotify/models/saved_album.rb', line 7 def added_at @added_at end |
#album ⇒ Object (readonly)
Returns the value of attribute album.
7 8 9 |
# File 'lib/spotify/models/saved_album.rb', line 7 def album @album end |