Sha256: 6895a9282010e226881779fe9618c115fa5a5e4392ed161abe81d5c9c4f8fc97
Contents?: true
Size: 574 Bytes
Versions: 1
Compression:
Stored size: 574 Bytes
Contents
module Weather class Condition # the weather condition code, detailed at http://developer.yahoo.com/weather attr_reader :code # the date and time associated with these conditions. attr_reader :date # the temperature of the location. attr_reader :temp # the brief prose text description of the weather conditions of the location. attr_reader :text def initialize(payload) @code = payload[:code].to_i @date = Utils.parse_time payload[:date] @temp = payload[:temp].to_i @text = payload[:text] end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
weather-api-1.2.0 | lib/weather-api/condition.rb |