Sha256: 9d23a9485f18df57e50862a665e556f504c4680e31cc26580181eaefbf9884b4
Contents?: true
Size: 1.12 KB
Versions: 1
Compression:
Stored size: 1.12 KB
Contents
module Beatport module Catalog class Track < Item has_many :genres, Genre has_many :sub_genres, Genre has_many :artists, Artist has_many :charts, Chart has_one :release, Release has_one :label, Label has_one :price, Price has_one :images, Images has_one :audio_format_fee, AudioFormatFee has_one :key, Keys # Returns the track with the given id def self.find(id) Client.retrieve('tracks', Track, :id => id).first end # Returns all the tracks matching the criterea def self.all(*args) Client.retrieve 'tracks', Track, *args end def self.most_popular(*args) Client.retrieve 'most-popular', Track, *args end def self.most_popular_for_genre(*args) Client.retrieve "most-popular/genre", Track, *args end def self.most_popular_for_artist(*args) Client.retrieve "most-popular/artist", Track, *args end def self.most_popular_for_label(*args) Client.retrieve "most-popular/label", Track, *args end end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
beatport-0.1.1 | lib/beatport/catalog/track.rb |