Class: Factbook::Codes::Code

Inherits:
Object
  • Object
show all
Defined in:
lib/factbook-codes/codes.rb

Overview

nested class

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#categoryObject

todo: add notes (country affiliation) - why? why not??



22
23
24
# File 'lib/factbook-codes/codes.rb', line 22

def category
  @category
end

#codeObject

todo: add notes (country affiliation) - why? why not??



22
23
24
# File 'lib/factbook-codes/codes.rb', line 22

def code
  @code
end

#nameObject

todo: add notes (country affiliation) - why? why not??



22
23
24
# File 'lib/factbook-codes/codes.rb', line 22

def name
  @name
end

#regionObject

todo: add notes (country affiliation) - why? why not??



22
23
24
# File 'lib/factbook-codes/codes.rb', line 22

def region
  @region
end

Instance Method Details

#region_slugObject

todo/check: add aliases e.g. - why? why not?

country_code => code
country_name => name
region_name  => region


32
# File 'lib/factbook-codes/codes.rb', line 32

def region_slug() Factbook.region_to_slug( @region ); end