Class: Countir::AccountCode
- Inherits:
-
Object
- Object
- Countir::AccountCode
- Defined in:
- lib/countir/resources/account_code.rb
Instance Attribute Summary collapse
-
#account_name ⇒ Object
Returns the value of attribute account_name.
-
#account_name_en ⇒ Object
Returns the value of attribute account_name_en.
-
#account_type ⇒ Object
Returns the value of attribute account_type.
-
#id ⇒ Object
Returns the value of attribute id.
-
#phonetic_kana ⇒ Object
Returns the value of attribute phonetic_kana.
-
#phonetic_romaji ⇒ Object
Returns the value of attribute phonetic_romaji.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(id:, account_name:, account_name_en:, phonetic_kana:, phonetic_romaji:, account_type:) ⇒ AccountCode
constructor
A new instance of AccountCode.
Constructor Details
#initialize(id:, account_name:, account_name_en:, phonetic_kana:, phonetic_romaji:, account_type:) ⇒ AccountCode
Returns a new instance of AccountCode.
5 6 7 8 9 10 11 12 |
# File 'lib/countir/resources/account_code.rb', line 5 def initialize(id:, account_name:, account_name_en:, phonetic_kana:, phonetic_romaji:, account_type:) self.id = id self.account_name = account_name self.account_name_en = account_name_en self.phonetic_kana = phonetic_kana self.phonetic_romaji = phonetic_romaji self.account_type = account_type end |
Instance Attribute Details
#account_name ⇒ Object
Returns the value of attribute account_name.
3 4 5 |
# File 'lib/countir/resources/account_code.rb', line 3 def account_name @account_name end |
#account_name_en ⇒ Object
Returns the value of attribute account_name_en.
3 4 5 |
# File 'lib/countir/resources/account_code.rb', line 3 def account_name_en @account_name_en end |
#account_type ⇒ Object
Returns the value of attribute account_type.
3 4 5 |
# File 'lib/countir/resources/account_code.rb', line 3 def account_type @account_type end |
#id ⇒ Object
Returns the value of attribute id.
3 4 5 |
# File 'lib/countir/resources/account_code.rb', line 3 def id @id end |
#phonetic_kana ⇒ Object
Returns the value of attribute phonetic_kana.
3 4 5 |
# File 'lib/countir/resources/account_code.rb', line 3 def phonetic_kana @phonetic_kana end |
#phonetic_romaji ⇒ Object
Returns the value of attribute phonetic_romaji.
3 4 5 |
# File 'lib/countir/resources/account_code.rb', line 3 def phonetic_romaji @phonetic_romaji end |
Class Method Details
.response_schema(data) ⇒ Object
14 15 16 17 18 19 20 21 22 23 24 25 |
# File 'lib/countir/resources/account_code.rb', line 14 def self.response_schema(data) data.map do |r| self.new( id: r["id"], account_name: r["account_name"], account_name_en: r["account_name_en"], phonetic_kana: r["phonetic_kana"], phonetic_romaji: r["phonetic_romaji"], account_type: r["account_type"] ) end end |