Class: Torasup::Location

Inherits:
Object
  • Object
show all
Defined in:
lib/torasup/location.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(country_id, area_code) ⇒ Location

Returns a new instance of Location.



5
6
7
8
9
# File 'lib/torasup/location.rb', line 5

def initialize(country_id, area_code)
  @country_id = country_id
  @area = Torasup.area_code(country_id, area_code)
  @area_code = area_code if @area
end

Instance Attribute Details

#areaObject

Returns the value of attribute area.



3
4
5
# File 'lib/torasup/location.rb', line 3

def area
  @area
end

#area_codeObject

Returns the value of attribute area_code.



3
4
5
# File 'lib/torasup/location.rb', line 3

def area_code
  @area_code
end

#country_idObject

Returns the value of attribute country_id.



3
4
5
# File 'lib/torasup/location.rb', line 3

def country_id
  @country_id
end