Sha256: 0cb18cdf0a2628085b009ec338e38665257cac519de55d2cf26320c088a98ed6

Contents?: true

Size: 512 Bytes

Versions: 10

Compression:

Stored size: 512 Bytes

Contents

require "pp"
require "pry"
require "mechanize"
require "ecfs/daily_release"

module ECFS

  class DailyReleasesQuery
    attr_accessor :day
    attr_accessor :month
    attr_accessor :year

    def initialize
    end
    
    def get
      url = "http://transition.fcc.gov/Daily_Releases/Daily_Business/#{@year}/db#{@month}#{@day}/"
      agent = Mechanize.new
      page = agent.get(url)
      
      links = page.search('a')
      links.shift
      
      ECFS::DailyRelease.new(links, url)
    end

  end
end

Version data entries

10 entries across 10 versions & 1 rubygems

Version Path
ecfs-0.6.0 lib/ecfs/daily_releases_query.rb
ecfs-0.5.1 lib/ecfs/daily_releases_query.rb
ecfs-0.5.0 lib/ecfs/daily_releases_query.rb
ecfs-0.4.1 lib/ecfs/daily_releases_query.rb
ecfs-0.4.0 lib/ecfs/daily_releases_query.rb
ecfs-0.3.5 lib/ecfs/daily_releases_query.rb
ecfs-0.3.4 lib/ecfs/daily_releases_query.rb
ecfs-0.3.3 lib/ecfs/daily_releases_query.rb
ecfs-0.3.2 lib/ecfs/daily_releases_query.rb
ecfs-0.3.1 lib/ecfs/daily_releases_query.rb