class Beatport::Catalog::Genre
Public Class Methods
all(options = {})
click to toggle source
Returns all the genres
# File lib/beatport/catalog/genre.rb, line 17 def self.all(options = {}) Client.retrieve 'genres', Genre, options end
find(key)
click to toggle source
Returns the genre with the given id or slug
# File lib/beatport/catalog/genre.rb, line 12 def self.find(key) Client.retrieve 'genres', Genre, :key => key, :string_key_type => :slug, :subgenres => true end
overview()
click to toggle source
# File lib/beatport/catalog/genre.rb, line 21 def self.overview Client.retrieve 'genres/overview', Genre end
Public Instance Methods
slideshow()
click to toggle source
Returns the slideshow for the genre
# File lib/beatport/catalog/genre.rb, line 31 def slideshow @slideshow ||= Slideshow.find(id) end
top_downloads()
click to toggle source
Returns the top downloads for the genre
# File lib/beatport/catalog/genre.rb, line 26 def top_downloads @top_downloads ||= Track.most_popular_for_genre(id) end