class DayOfMonth

Attributes

days[RW]
title[RW]

Public Class Methods

array_from_hash_array(hash_array) click to toggle source

utility method to take the array of hashes returned by the scraper and turn them into instances of this object

# File lib/dayofmonth.rb, line 5
def self.array_from_hash_array(hash_array)
        hash_array.collect {|hash|
                self.new(hash)
        }
end
new(hash) click to toggle source
# File lib/dayofmonth.rb, line 11
def initialize(hash)
        hash.each do |k,v|
                self.send("#{k}=",v)
        end
        @days = @days.collect {|day| NationalDay.new(day)}
end