Class: ZenginCode::Bank
- Inherits:
-
Object
- Object
- ZenginCode::Bank
- Defined in:
- lib/zengin_code/bank.rb
Instance Attribute Summary collapse
-
#branches ⇒ Object
readonly
Returns the value of attribute branches.
-
#code ⇒ Object
readonly
Returns the value of attribute code.
-
#hira ⇒ Object
readonly
Returns the value of attribute hira.
-
#kana ⇒ Object
readonly
Returns the value of attribute kana.
-
#name ⇒ Object
readonly
Returns the value of attribute name.
-
#roma ⇒ Object
readonly
Returns the value of attribute roma.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(options = {}) ⇒ Bank
constructor
A new instance of Bank.
Constructor Details
#initialize(options = {}) ⇒ Bank
Returns a new instance of Bank.
20 21 22 23 24 25 26 27 28 |
# File 'lib/zengin_code/bank.rb', line 20 def initialize( = {}) @code = ['code'] @name = ['name'] @kana = ['kana'] @hira = ['hira'] @roma = ['roma'] @branches = {} self.class[code] = self end |
Instance Attribute Details
#branches ⇒ Object (readonly)
Returns the value of attribute branches.
29 30 31 |
# File 'lib/zengin_code/bank.rb', line 29 def branches @branches end |
#code ⇒ Object (readonly)
Returns the value of attribute code.
29 30 31 |
# File 'lib/zengin_code/bank.rb', line 29 def code @code end |
#hira ⇒ Object (readonly)
Returns the value of attribute hira.
29 30 31 |
# File 'lib/zengin_code/bank.rb', line 29 def hira @hira end |
#kana ⇒ Object (readonly)
Returns the value of attribute kana.
29 30 31 |
# File 'lib/zengin_code/bank.rb', line 29 def kana @kana end |
#name ⇒ Object (readonly)
Returns the value of attribute name.
29 30 31 |
# File 'lib/zengin_code/bank.rb', line 29 def name @name end |
#roma ⇒ Object (readonly)
Returns the value of attribute roma.
29 30 31 |
# File 'lib/zengin_code/bank.rb', line 29 def roma @roma end |
Class Method Details
.[](code) ⇒ Object
7 8 9 |
# File 'lib/zengin_code/bank.rb', line 7 def [](code) @banks[code] end |
.[]=(code, bank) ⇒ Object
11 12 13 |
# File 'lib/zengin_code/bank.rb', line 11 def []=(code, bank) @banks[code] = bank end |
.all ⇒ Object
15 16 17 |
# File 'lib/zengin_code/bank.rb', line 15 def all @banks end |