Class: Muzak::Album
- Inherits:
-
Object
- Object
- Muzak::Album
- Defined in:
- lib/muzak/album.rb
Overview
Represents a collection of songs for muzak.
Instance Attribute Summary collapse
-
#cover_art ⇒ String
readonly
The path to the album's cover art.
-
#songs ⇒ Array<Muzak::Song>
readonly
The album's songs.
-
#title ⇒ String
readonly
The album's title.
Instance Method Summary collapse
-
#initialize(title, songs, cover_art = nil) ⇒ Album
constructor
A new instance of Album.
Constructor Details
#initialize(title, songs, cover_art = nil) ⇒ Album
Returns a new instance of Album.
16 17 18 19 20 |
# File 'lib/muzak/album.rb', line 16 def initialize(title, songs, cover_art = nil) @title = title @songs = songs @cover_art = cover_art end |
Instance Attribute Details
#cover_art ⇒ String (readonly)
Returns the path to the album's cover art.
11 12 13 |
# File 'lib/muzak/album.rb', line 11 def cover_art @cover_art end |
#songs ⇒ Array<Muzak::Song> (readonly)
Returns the album's songs.
8 9 10 |
# File 'lib/muzak/album.rb', line 8 def songs @songs end |
#title ⇒ String (readonly)
Returns the album's title.
5 6 7 |
# File 'lib/muzak/album.rb', line 5 def title @title end |