Class: ISO4217::Code

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

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(table) ⇒ Code

Returns a new instance of Code.



7
8
9
10
11
12
13
14
# File 'lib/iso4217.rb', line 7

def initialize(table)
  @code = table[:code]
  @num = table[:num]
  @locations = table[:locations]
  @currency = table[:currency]
  @ccc = table[:ccc]
  @obsolete = table[:obsolete]
end

Instance Attribute Details

#cccObject (readonly)

Returns the value of attribute ccc.



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

def ccc
  @ccc
end

#codeObject (readonly)

Returns the value of attribute code.



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

def code
  @code
end

#currencyObject (readonly)

Returns the value of attribute currency.



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

def currency
  @currency
end

#locationsObject (readonly)

Returns the value of attribute locations.



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

def locations
  @locations
end

#numObject (readonly)

Returns the value of attribute num.



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

def num
  @num
end

Instance Method Details

#obsoleteObject



18
# File 'lib/iso4217.rb', line 18

def obsolete; CODE[@obsolete]; end

#to_sObject



16
# File 'lib/iso4217.rb', line 16

def to_s; @currency; end