Class: GeoIP::City
- Inherits:
-
Struct
- Object
- Struct
- GeoIP::City
- Defined in:
- lib/geoip.rb
Instance Attribute Summary collapse
-
#area_code ⇒ Object
Returns the value of attribute area_code.
-
#city ⇒ Object
Returns the value of attribute city.
-
#continent_code ⇒ Object
Returns the value of attribute continent_code.
-
#country_code ⇒ Object
Returns the value of attribute country_code.
-
#country_code3 ⇒ Object
Returns the value of attribute country_code3.
-
#country_name ⇒ Object
Returns the value of attribute country_name.
-
#ip ⇒ Object
Returns the value of attribute ip.
-
#latitude ⇒ Object
Returns the value of attribute latitude.
-
#longitude ⇒ Object
Returns the value of attribute longitude.
-
#metrocode ⇒ Object
Returns the value of attribute metrocode.
-
#region_code ⇒ Object
Returns the value of attribute region_code.
-
#request ⇒ Object
Returns the value of attribute request.
-
#timezone ⇒ Object
Returns the value of attribute timezone.
-
#zipcode ⇒ Object
Returns the value of attribute zipcode.
Instance Method Summary collapse
Instance Attribute Details
#area_code ⇒ Object
Returns the value of attribute area_code
115 116 117 |
# File 'lib/geoip.rb', line 115 def area_code @area_code end |
#city ⇒ Object
Returns the value of attribute city
115 116 117 |
# File 'lib/geoip.rb', line 115 def city @city end |
#continent_code ⇒ Object
Returns the value of attribute continent_code
115 116 117 |
# File 'lib/geoip.rb', line 115 def continent_code @continent_code end |
#country_code ⇒ Object
Returns the value of attribute country_code
115 116 117 |
# File 'lib/geoip.rb', line 115 def country_code @country_code end |
#country_code3 ⇒ Object
Returns the value of attribute country_code3
115 116 117 |
# File 'lib/geoip.rb', line 115 def country_code3 @country_code3 end |
#country_name ⇒ Object
Returns the value of attribute country_name
115 116 117 |
# File 'lib/geoip.rb', line 115 def country_name @country_name end |
#ip ⇒ Object
Returns the value of attribute ip
115 116 117 |
# File 'lib/geoip.rb', line 115 def ip @ip end |
#latitude ⇒ Object
Returns the value of attribute latitude
115 116 117 |
# File 'lib/geoip.rb', line 115 def latitude @latitude end |
#longitude ⇒ Object
Returns the value of attribute longitude
115 116 117 |
# File 'lib/geoip.rb', line 115 def longitude @longitude end |
#metrocode ⇒ Object
Returns the value of attribute metrocode
115 116 117 |
# File 'lib/geoip.rb', line 115 def metrocode @metrocode end |
#region_code ⇒ Object
Returns the value of attribute region_code
115 116 117 |
# File 'lib/geoip.rb', line 115 def region_code @region_code end |
#request ⇒ Object
Returns the value of attribute request
115 116 117 |
# File 'lib/geoip.rb', line 115 def request @request end |
#timezone ⇒ Object
Returns the value of attribute timezone
115 116 117 |
# File 'lib/geoip.rb', line 115 def timezone @timezone end |
#zipcode ⇒ Object
Returns the value of attribute zipcode
115 116 117 |
# File 'lib/geoip.rb', line 115 def zipcode @zipcode end |
Instance Method Details
#to_hash ⇒ Object
118 119 120 |
# File 'lib/geoip.rb', line 118 def to_hash Hash[each_pair.to_a] end |