Class: WeatherHacks::LWWS::Location
- Inherits:
-
Object
- Object
- WeatherHacks::LWWS::Location
- Defined in:
- lib/weatherhacks/lwws.rb
Instance Attribute Summary collapse
-
#area ⇒ Object
readonly
Returns the value of attribute area.
-
#city ⇒ Object
readonly
Returns the value of attribute city.
-
#pref ⇒ Object
readonly
Returns the value of attribute pref.
Instance Method Summary collapse
-
#initialize(elt) ⇒ Location
constructor
A new instance of Location.
Constructor Details
#initialize(elt) ⇒ Location
Returns a new instance of Location.
50 51 52 53 54 |
# File 'lib/weatherhacks/lwws.rb', line 50 def initialize(elt) @area = elt.attributes["area"] @pref = elt.attributes["pref"] @city = elt.attributes["city"] end |
Instance Attribute Details
#area ⇒ Object (readonly)
Returns the value of attribute area.
49 50 51 |
# File 'lib/weatherhacks/lwws.rb', line 49 def area @area end |
#city ⇒ Object (readonly)
Returns the value of attribute city.
49 50 51 |
# File 'lib/weatherhacks/lwws.rb', line 49 def city @city end |
#pref ⇒ Object (readonly)
Returns the value of attribute pref.
49 50 51 |
# File 'lib/weatherhacks/lwws.rb', line 49 def pref @pref end |