Sha256: 5ee3e39a6d19de34ba84e255bd20bc6cf0f853d8e808096becb93db461e47e90
Contents?: true
Size: 778 Bytes
Versions: 7
Compression:
Stored size: 778 Bytes
Contents
module MarketBot module Android # Search query pages are extremely similar to leaderboard pages. # Amazingly, this inheritence hack works! class SearchQuery < MarketBot::Android::Leaderboard def initialze(query, options={}) super(query, nil, options) end def market_urls(options={}) results = [] min_page = options[:min_page] || 1 max_page = options[:max_page] || 25 (min_page..max_page).each do |page| start_val = (page - 1) * 24 url = "https://play.google.com/store/search?" url << "q=#{URI.escape(identifier)}&" url << "c=apps&start=#{start_val}&" url << "num=24" results << url end results end end end end
Version data entries
7 entries across 7 versions & 1 rubygems