Class: AmpacheSong
- Inherits:
-
Object
- Object
- AmpacheSong
- Defined in:
- lib/lib-classes.rb
Instance Attribute Summary collapse
-
#album ⇒ Object
readonly
Returns the value of attribute album.
-
#artist ⇒ Object
readonly
Returns the value of attribute artist.
-
#title ⇒ Object
readonly
Returns the value of attribute title.
-
#uid ⇒ Object
readonly
Returns the value of attribute uid.
-
#url ⇒ Object
readonly
Returns the value of attribute url.
Instance Method Summary collapse
- #add_to_playlist(pl) ⇒ Object
-
#initialize(ar, uid, title, artist, album, url) ⇒ AmpacheSong
constructor
A new instance of AmpacheSong.
Constructor Details
#initialize(ar, uid, title, artist, album, url) ⇒ AmpacheSong
Returns a new instance of AmpacheSong.
52 53 54 55 56 57 58 59 |
# File 'lib/lib-classes.rb', line 52 def initialize(ar, uid, title, artist, album, url) @ar = ar @uid = uid @title = title @artist = artist @album = album @url = url end |
Instance Attribute Details
#album ⇒ Object (readonly)
Returns the value of attribute album.
61 62 63 |
# File 'lib/lib-classes.rb', line 61 def album @album end |
#artist ⇒ Object (readonly)
Returns the value of attribute artist.
61 62 63 |
# File 'lib/lib-classes.rb', line 61 def artist @artist end |
#title ⇒ Object (readonly)
Returns the value of attribute title.
61 62 63 |
# File 'lib/lib-classes.rb', line 61 def title @title end |
#uid ⇒ Object (readonly)
Returns the value of attribute uid.
61 62 63 |
# File 'lib/lib-classes.rb', line 61 def uid @uid end |
#url ⇒ Object (readonly)
Returns the value of attribute url.
61 62 63 |
# File 'lib/lib-classes.rb', line 61 def url @url end |
Instance Method Details
#add_to_playlist(pl) ⇒ Object
63 64 65 |
# File 'lib/lib-classes.rb', line 63 def add_to_playlist(pl) pl.add(self) end |