Class: TimezoneGeo

Inherits:
Object
  • Object
show all
Defined in:
lib/ipgeolocation_io/TimezoneGeo.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(json) ⇒ TimezoneGeo

Returns a new instance of TimezoneGeo.



12
13
14
15
16
17
18
19
20
21
22
# File 'lib/ipgeolocation_io/TimezoneGeo.rb', line 12

def initialize(json)
  @countryCode2 = json["country_code2"];
  @countryCode3 = json["country_code3"];
  @countryName = json["country_name"];
  @stateProvince = json["state_prov"];
  @district = json["district"];
  @city = json["city"];
  @zipCode = json["zipcode"];
  @latitude = json["latitude"];
  @longitude = json["longitude"];
end

Instance Attribute Details

#cityObject (readonly)

Returns the value of attribute city.



7
8
9
# File 'lib/ipgeolocation_io/TimezoneGeo.rb', line 7

def city
  @city
end

#countryCode2Object (readonly)

Returns the value of attribute countryCode2.



2
3
4
# File 'lib/ipgeolocation_io/TimezoneGeo.rb', line 2

def countryCode2
  @countryCode2
end

#countryCode3Object (readonly)

Returns the value of attribute countryCode3.



3
4
5
# File 'lib/ipgeolocation_io/TimezoneGeo.rb', line 3

def countryCode3
  @countryCode3
end

#countryNameObject (readonly)

Returns the value of attribute countryName.



4
5
6
# File 'lib/ipgeolocation_io/TimezoneGeo.rb', line 4

def countryName
  @countryName
end

#districtObject (readonly)

Returns the value of attribute district.



6
7
8
# File 'lib/ipgeolocation_io/TimezoneGeo.rb', line 6

def district
  @district
end

#latitudeObject (readonly)

Returns the value of attribute latitude.



9
10
11
# File 'lib/ipgeolocation_io/TimezoneGeo.rb', line 9

def latitude
  @latitude
end

#longitudeObject (readonly)

Returns the value of attribute longitude.



10
11
12
# File 'lib/ipgeolocation_io/TimezoneGeo.rb', line 10

def longitude
  @longitude
end

#stateProvinceObject (readonly)

Returns the value of attribute stateProvince.



5
6
7
# File 'lib/ipgeolocation_io/TimezoneGeo.rb', line 5

def stateProvince
  @stateProvince
end

#zipCodeObject (readonly)

Returns the value of attribute zipCode.



8
9
10
# File 'lib/ipgeolocation_io/TimezoneGeo.rb', line 8

def zipCode
  @zipCode
end