It seems that every time I implement a class in Ruby I later find out
someone has already done a much better job than myself.
So before I take the time to implement a TimeRange class myself, I
I’d ask if there was anything out there similar.
I’d like to be able to do something like the following:
start_date = Time.parse “9/1/2006”
end_date = Time.parse “9/2/2006”
r = TimeRange.new(start_date, end_date)
r.each_hour do |hour|
r.each_day do |day|
r.each(1800) do |half_hour|
Any suggestions are welcome.