Class: Weathercom::DayPartForecast
- Inherits:
-
Object
- Object
- Weathercom::DayPartForecast
- Defined in:
- lib/weathercom/day_part_forecast.rb
Instance Method Summary collapse
-
#cut_narrative ⇒ Object
Narrative without the temperature and wind speed, which is available via other attributes.
-
#initialize(info) ⇒ DayPartForecast
constructor
A new instance of DayPartForecast.
Constructor Details
#initialize(info) ⇒ DayPartForecast
Returns a new instance of DayPartForecast.
5 6 7 |
# File 'lib/weathercom/day_part_forecast.rb', line 5 def initialize(info) @info = info.dup.freeze end |
Instance Method Details
#cut_narrative ⇒ Object
Narrative without the temperature and wind speed, which is available via other attributes
39 40 41 |
# File 'lib/weathercom/day_part_forecast.rb', line 39 def cut_narrative narrative.sub(/\..*/, '') end |