Class: Tenkit::WeatherAlertSummary

Inherits:
Object
  • Object
show all
Defined in:
lib/tenkit/weather_alert_summary.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(weather_alert) ⇒ WeatherAlertSummary

Returns a new instance of WeatherAlertSummary.



20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
# File 'lib/tenkit/weather_alert_summary.rb', line 20

def initialize(weather_alert)
  @area_id = weather_alert['areaId']
  @area_name = weather_alert['areaName']
  @certainty = weather_alert['certainty']
  @country_code = weather_alert['countryCode']
  @description = weather_alert['description']
  @details_url = weather_alert['detailsUrl']
  @effective_time = weather_alert['effectiveTime']
  @event_end_time = weather_alert['eventEndTime']
  @event_onset_time = weather_alert['eventOnsetTime']
  @expire_time = weather_alert['expireTime']
  @id = weather_alert['id']
  @issued_time = weather_alert['issued_time']
  @responses = weather_alert['responses']
  @severity = weather_alert['severity']
  @source = weather_alert['source']
  @urgency = weather_alert['urgency']
end

Instance Attribute Details

#area_idObject (readonly)

Returns the value of attribute area_id.



3
4
5
# File 'lib/tenkit/weather_alert_summary.rb', line 3

def area_id
  @area_id
end

#area_nameObject (readonly)

Returns the value of attribute area_name.



3
4
5
# File 'lib/tenkit/weather_alert_summary.rb', line 3

def area_name
  @area_name
end

#certaintyObject (readonly)

Returns the value of attribute certainty.



3
4
5
# File 'lib/tenkit/weather_alert_summary.rb', line 3

def certainty
  @certainty
end

#country_codeObject (readonly)

Returns the value of attribute country_code.



3
4
5
# File 'lib/tenkit/weather_alert_summary.rb', line 3

def country_code
  @country_code
end

#descriptionObject (readonly)

Returns the value of attribute description.



3
4
5
# File 'lib/tenkit/weather_alert_summary.rb', line 3

def description
  @description
end

#details_urlObject (readonly)

Returns the value of attribute details_url.



3
4
5
# File 'lib/tenkit/weather_alert_summary.rb', line 3

def details_url
  @details_url
end

#effective_timeObject (readonly)

Returns the value of attribute effective_time.



3
4
5
# File 'lib/tenkit/weather_alert_summary.rb', line 3

def effective_time
  @effective_time
end

#event_end_timeObject (readonly)

Returns the value of attribute event_end_time.



3
4
5
# File 'lib/tenkit/weather_alert_summary.rb', line 3

def event_end_time
  @event_end_time
end

#event_onset_timeObject (readonly)

Returns the value of attribute event_onset_time.



3
4
5
# File 'lib/tenkit/weather_alert_summary.rb', line 3

def event_onset_time
  @event_onset_time
end

#expire_timeObject (readonly)

Returns the value of attribute expire_time.



3
4
5
# File 'lib/tenkit/weather_alert_summary.rb', line 3

def expire_time
  @expire_time
end

#idObject (readonly)

Returns the value of attribute id.



3
4
5
# File 'lib/tenkit/weather_alert_summary.rb', line 3

def id
  @id
end

#issued_timeObject (readonly)

Returns the value of attribute issued_time.



3
4
5
# File 'lib/tenkit/weather_alert_summary.rb', line 3

def issued_time
  @issued_time
end

#responsesObject (readonly)

Returns the value of attribute responses.



3
4
5
# File 'lib/tenkit/weather_alert_summary.rb', line 3

def responses
  @responses
end

#severityObject (readonly)

Returns the value of attribute severity.



3
4
5
# File 'lib/tenkit/weather_alert_summary.rb', line 3

def severity
  @severity
end

#sourceObject (readonly)

Returns the value of attribute source.



3
4
5
# File 'lib/tenkit/weather_alert_summary.rb', line 3

def source
  @source
end

#urgencyObject (readonly)

Returns the value of attribute urgency.



3
4
5
# File 'lib/tenkit/weather_alert_summary.rb', line 3

def urgency
  @urgency
end