Class: WeatherWeasel::Conditions

Inherits:
Object
  • Object
show all
Defined in:
lib/weather_weasel/conditions.rb

Instance Method Summary collapse

Constructor Details

#initialize(city, state, temperature_format, client) ⇒ Conditions

Returns a new instance of Conditions.



4
5
6
7
8
9
# File 'lib/weather_weasel/conditions.rb', line 4

def initialize(city, state, temperature_format, client)
  @city = city
  @state = state
  @temperature_format = temperature_format
  @client = client
end

Instance Method Details

#raw_dataObject



11
12
13
# File 'lib/weather_weasel/conditions.rb', line 11

def raw_data
  @data ||= @client.parse_url("conditions/q/#{@state}/#{@city}.json")
end