Class: GeoIP::Country
- Inherits:
-
Struct
- Object
- Struct
- GeoIP::Country
- Defined in:
- lib/geoip.rb
Instance Attribute Summary collapse
-
#continent_code ⇒ Object
Returns the value of attribute continent_code.
-
#country_code ⇒ Object
Returns the value of attribute country_code.
-
#country_code2 ⇒ Object
Returns the value of attribute country_code2.
-
#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.
-
#request ⇒ Object
Returns the value of attribute request.
Instance Method Summary collapse
Instance Attribute Details
#continent_code ⇒ Object
Returns the value of attribute continent_code
107 108 109 |
# File 'lib/geoip.rb', line 107 def continent_code @continent_code end |
#country_code ⇒ Object
Returns the value of attribute country_code
107 108 109 |
# File 'lib/geoip.rb', line 107 def country_code @country_code end |
#country_code2 ⇒ Object
Returns the value of attribute country_code2
107 108 109 |
# File 'lib/geoip.rb', line 107 def country_code2 @country_code2 end |
#country_code3 ⇒ Object
Returns the value of attribute country_code3
107 108 109 |
# File 'lib/geoip.rb', line 107 def country_code3 @country_code3 end |
#country_name ⇒ Object
Returns the value of attribute country_name
107 108 109 |
# File 'lib/geoip.rb', line 107 def country_name @country_name end |
#ip ⇒ Object
Returns the value of attribute ip
107 108 109 |
# File 'lib/geoip.rb', line 107 def ip @ip end |
#request ⇒ Object
Returns the value of attribute request
107 108 109 |
# File 'lib/geoip.rb', line 107 def request @request end |
Instance Method Details
#to_hash ⇒ Object
109 110 111 |
# File 'lib/geoip.rb', line 109 def to_hash Hash[each_pair.to_a] end |