Class: Spotify::Models::SavedAlbum

Inherits:
Object
  • Object
show all
Defined in:
lib/spotify/models/saved_album.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

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_atObject (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

#albumObject (readonly)

Returns the value of attribute album.



7
8
9
# File 'lib/spotify/models/saved_album.rb', line 7

def album
  @album
end