Class: Ingenico::Connect::SDK::Domain::Definitions::BankAccountBban
- Inherits:
-
BankAccount
show all
- Defined in:
- lib/ingenico/connect/sdk/domain/definitions/bank_account_bban.rb
Instance Attribute Summary collapse
Attributes inherited from BankAccount
#account_holder_name
Instance Method Summary
collapse
new_from_hash
Instance Attribute Details
#account_number ⇒ String
17
18
19
|
# File 'lib/ingenico/connect/sdk/domain/definitions/bank_account_bban.rb', line 17
def account_number
@account_number
end
|
#bank_code ⇒ String
17
18
19
|
# File 'lib/ingenico/connect/sdk/domain/definitions/bank_account_bban.rb', line 17
def bank_code
@bank_code
end
|
#bank_name ⇒ String
17
18
19
|
# File 'lib/ingenico/connect/sdk/domain/definitions/bank_account_bban.rb', line 17
def bank_name
@bank_name
end
|
#branch_code ⇒ String
17
18
19
|
# File 'lib/ingenico/connect/sdk/domain/definitions/bank_account_bban.rb', line 17
def branch_code
@branch_code
end
|
#check_digit ⇒ String
17
18
19
|
# File 'lib/ingenico/connect/sdk/domain/definitions/bank_account_bban.rb', line 17
def check_digit
@check_digit
end
|
#country_code ⇒ String
17
18
19
|
# File 'lib/ingenico/connect/sdk/domain/definitions/bank_account_bban.rb', line 17
def country_code
@country_code
end
|
Instance Method Details
#from_hash(hash) ⇒ Object
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
|
# File 'lib/ingenico/connect/sdk/domain/definitions/bank_account_bban.rb', line 43
def from_hash(hash)
super
if hash.has_key? 'accountNumber'
@account_number = hash['accountNumber']
end
if hash.has_key? 'bankCode'
@bank_code = hash['bankCode']
end
if hash.has_key? 'bankName'
@bank_name = hash['bankName']
end
if hash.has_key? 'branchCode'
@branch_code = hash['branchCode']
end
if hash.has_key? 'checkDigit'
@check_digit = hash['checkDigit']
end
if hash.has_key? 'countryCode'
@country_code = hash['countryCode']
end
end
|
#to_h ⇒ Hash
32
33
34
35
36
37
38
39
40
41
|
# File 'lib/ingenico/connect/sdk/domain/definitions/bank_account_bban.rb', line 32
def to_h
hash = super
hash['accountNumber'] = @account_number unless @account_number.nil?
hash['bankCode'] = @bank_code unless @bank_code.nil?
hash['bankName'] = @bank_name unless @bank_name.nil?
hash['branchCode'] = @branch_code unless @branch_code.nil?
hash['checkDigit'] = @check_digit unless @check_digit.nil?
hash['countryCode'] = @country_code unless @country_code.nil?
hash
end
|