Class: TopGeniusSongs::Song

Inherits:
Object
  • Object
show all
Defined in:
lib/top_genius_songs/song.rb

Constant Summary collapse

@@all =
[]

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#artistObject

Returns the value of attribute artist.



9
10
11
# File 'lib/top_genius_songs/song.rb', line 9

def artist
  @artist
end

#descriptionObject

Returns the value of attribute description.



9
10
11
# File 'lib/top_genius_songs/song.rb', line 9

def description
  @description
end

Returns the value of attribute link.



9
10
11
# File 'lib/top_genius_songs/song.rb', line 9

def link
  @link
end

#titleObject

Returns the value of attribute title.



9
10
11
# File 'lib/top_genius_songs/song.rb', line 9

def title
  @title
end

Class Method Details

.allObject



5
6
7
# File 'lib/top_genius_songs/song.rb', line 5

def self.all 
	@@all
end

Instance Method Details

#lyricsObject



11
12
13
# File 'lib/top_genius_songs/song.rb', line 11

def lyrics
	@lyrics ||= TopGeniusSongs::Scraper.get_lyrics(self.link)
end