Class: AxiomusApi::RegionsResponse::City
- Inherits:
-
Object
- Object
- AxiomusApi::RegionsResponse::City
- Defined in:
- lib/axiomus_api/response/regions_response.rb
Instance Attribute Summary collapse
-
#code ⇒ Object
Returns the value of attribute code.
-
#name ⇒ Object
Returns the value of attribute name.
Instance Method Summary collapse
-
#initialize(node) ⇒ City
constructor
A new instance of City.
Constructor Details
#initialize(node) ⇒ City
Returns a new instance of City.
8 9 10 11 |
# File 'lib/axiomus_api/response/regions_response.rb', line 8 def initialize(node) @code = node.xpath('@city_code').text.to_i @name = node.text end |
Instance Attribute Details
#code ⇒ Object
Returns the value of attribute code.
5 6 7 |
# File 'lib/axiomus_api/response/regions_response.rb', line 5 def code @code end |
#name ⇒ Object
Returns the value of attribute name.
6 7 8 |
# File 'lib/axiomus_api/response/regions_response.rb', line 6 def name @name end |