Class: Almanac

Inherits:
Weatherzone::Resource show all
Defined in:
lib/weatherzone/resources/almanac.rb

Instance Method Summary collapse

Methods inherited from Weatherzone::Resource

has_attribute, has_elements, inherited, #settings

Instance Method Details

#extremesObject



14
15
16
# File 'lib/weatherzone/resources/almanac.rb', line 14

def extremes
  @extremes ||= almanac_periods.detect { |ap| ap.code == "Extremes" }
end

#mtdObject



6
7
8
# File 'lib/weatherzone/resources/almanac.rb', line 6

def mtd
  @mtd ||= almanac_periods.detect { |ap| ap.code == "MTD" }
end

#ytdObject



10
11
12
# File 'lib/weatherzone/resources/almanac.rb', line 10

def ytd
  @ytd ||= almanac_periods.detect { |ap| ap.code == "YTD" }
end