Class: AppleMusic::Artist::Relationships
- Inherits:
-
Object
- Object
- AppleMusic::Artist::Relationships
- Defined in:
- lib/apple_music/artist/relationships.rb
Overview
Instance Attribute Summary collapse
-
#albums ⇒ Object
readonly
Returns the value of attribute albums.
-
#genres ⇒ Object
readonly
Returns the value of attribute genres.
-
#music_videos ⇒ Object
readonly
Returns the value of attribute music_videos.
-
#playlists ⇒ Object
readonly
Returns the value of attribute playlists.
-
#station ⇒ Object
readonly
Returns the value of attribute station.
Instance Method Summary collapse
-
#initialize(props = {}) ⇒ Relationships
constructor
A new instance of Relationships.
Constructor Details
#initialize(props = {}) ⇒ Relationships
Returns a new instance of Relationships.
9 10 11 12 13 14 15 |
# File 'lib/apple_music/artist/relationships.rb', line 9 def initialize(props = {}) @albums = Relationship.new(props['albums']).data @genres = Relationship.new(props['genres']).data @music_videos = Relationship.new(props['musicVideos']).data @playlists = Relationship.new(props['playlists']).data @station = Relationship.new(props['station']).data.first end |
Instance Attribute Details
#albums ⇒ Object (readonly)
Returns the value of attribute albums.
7 8 9 |
# File 'lib/apple_music/artist/relationships.rb', line 7 def albums @albums end |
#genres ⇒ Object (readonly)
Returns the value of attribute genres.
7 8 9 |
# File 'lib/apple_music/artist/relationships.rb', line 7 def genres @genres end |
#music_videos ⇒ Object (readonly)
Returns the value of attribute music_videos.
7 8 9 |
# File 'lib/apple_music/artist/relationships.rb', line 7 def music_videos @music_videos end |
#playlists ⇒ Object (readonly)
Returns the value of attribute playlists.
7 8 9 |
# File 'lib/apple_music/artist/relationships.rb', line 7 def playlists @playlists end |
#station ⇒ Object (readonly)
Returns the value of attribute station.
7 8 9 |
# File 'lib/apple_music/artist/relationships.rb', line 7 def station @station end |