Class: WeatherWeasel::Almanac
- Inherits:
-
Object
- Object
- WeatherWeasel::Almanac
- Defined in:
- lib/weather_weasel/almanac.rb
Instance Method Summary collapse
-
#initialize(city, state, tempature_format, client) ⇒ Almanac
constructor
A new instance of Almanac.
- #raw_data ⇒ Object
Constructor Details
#initialize(city, state, tempature_format, client) ⇒ Almanac
Returns a new instance of Almanac.
4 5 6 7 8 9 |
# File 'lib/weather_weasel/almanac.rb', line 4 def initialize(city, state, tempature_format, client) @city = city @state = state @tempature_format = tempature_format @client = client end |
Instance Method Details
#raw_data ⇒ Object
11 12 13 |
# File 'lib/weather_weasel/almanac.rb', line 11 def raw_data @data ||= @client.parse_url("almanac/q/#{@state}/#{@city}.json") end |