transferzero-sdk 1.5.0 → 1.9.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +9 -5
- data/docs/Currency.md +0 -2
- data/docs/CurrencyExchange.md +0 -2
- data/docs/CurrencyOpposite.md +3 -3
- data/docs/Document.md +3 -3
- data/docs/DocumentsApi.md +2 -74
- data/docs/PayinMethodDetails.md +3 -1
- data/docs/PayinMethodDetailsBTC.md +17 -0
- data/docs/PayoutMethod.md +1 -1
- data/docs/PayoutMethodDetails.md +17 -1
- data/docs/PayoutMethodDetailsBTC.md +23 -0
- data/docs/PayoutMethodDetailsGBPBank.md +29 -0
- data/docs/PayoutMethodDetailsIBAN.md +1 -1
- data/docs/PayoutMethodDetailsMobile.md +3 -1
- data/docs/PayoutMethodDetailsZARBank.md +35 -0
- data/docs/PoliticallyExposedPerson.md +31 -0
- data/docs/Recipient.md +1 -1
- data/docs/RecipientsApi.md +1 -1
- data/docs/Sender.md +72 -32
- data/docs/Transaction.md +3 -3
- data/lib/transferzero-sdk.rb +5 -0
- data/lib/transferzero-sdk/api/documents_api.rb +0 -63
- data/lib/transferzero-sdk/api/recipients_api.rb +2 -2
- data/lib/transferzero-sdk/api_client.rb +5 -3
- data/lib/transferzero-sdk/models/account.rb +70 -69
- data/lib/transferzero-sdk/models/account_list_response.rb +67 -66
- data/lib/transferzero-sdk/models/account_meta.rb +61 -60
- data/lib/transferzero-sdk/models/account_response.rb +66 -65
- data/lib/transferzero-sdk/models/account_validation_error.rb +61 -60
- data/lib/transferzero-sdk/models/account_validation_request.rb +164 -163
- data/lib/transferzero-sdk/models/account_validation_response.rb +66 -65
- data/lib/transferzero-sdk/models/account_validation_result.rb +61 -60
- data/lib/transferzero-sdk/models/api_log.rb +136 -135
- data/lib/transferzero-sdk/models/api_log_list_response.rb +70 -69
- data/lib/transferzero-sdk/models/api_log_response.rb +60 -59
- data/lib/transferzero-sdk/models/currency.rb +133 -142
- data/lib/transferzero-sdk/models/currency_exchange.rb +149 -158
- data/lib/transferzero-sdk/models/currency_exchange_list_response.rb +62 -61
- data/lib/transferzero-sdk/models/currency_list_response.rb +62 -61
- data/lib/transferzero-sdk/models/currency_opposite.rb +166 -165
- data/lib/transferzero-sdk/models/debit.rb +151 -150
- data/lib/transferzero-sdk/models/debit_list_request.rb +61 -60
- data/lib/transferzero-sdk/models/debit_list_response.rb +67 -66
- data/lib/transferzero-sdk/models/debit_request.rb +60 -59
- data/lib/transferzero-sdk/models/debit_request_wrapper.rb +80 -79
- data/lib/transferzero-sdk/models/debit_response.rb +60 -59
- data/lib/transferzero-sdk/models/document.rb +179 -177
- data/lib/transferzero-sdk/models/document_list_response.rb +67 -66
- data/lib/transferzero-sdk/models/document_request.rb +60 -59
- data/lib/transferzero-sdk/models/document_response.rb +60 -59
- data/lib/transferzero-sdk/models/document_webhook.rb +96 -95
- data/lib/transferzero-sdk/models/error_status.rb +66 -65
- data/lib/transferzero-sdk/models/field_description.rb +95 -94
- data/lib/transferzero-sdk/models/field_select_validation.rb +70 -69
- data/lib/transferzero-sdk/models/field_validation.rb +78 -77
- data/lib/transferzero-sdk/models/pagination.rb +97 -96
- data/lib/transferzero-sdk/models/pagination_meta.rb +60 -59
- data/lib/transferzero-sdk/models/payin_method.rb +97 -96
- data/lib/transferzero-sdk/models/payin_method_details.rb +122 -110
- data/lib/transferzero-sdk/models/payin_method_details_btc.rb +204 -0
- data/lib/transferzero-sdk/models/payin_method_details_mobile.rb +75 -74
- data/lib/transferzero-sdk/models/payin_method_details_ngn_bank.rb +71 -70
- data/lib/transferzero-sdk/models/payin_method_request.rb +60 -59
- data/lib/transferzero-sdk/models/payment_method.rb +109 -108
- data/lib/transferzero-sdk/models/payment_method_list_response.rb +61 -60
- data/lib/transferzero-sdk/models/payment_method_opposite.rb +124 -123
- data/lib/transferzero-sdk/models/payout_method.rb +107 -106
- data/lib/transferzero-sdk/models/payout_method_bank_account_type_enum.rb +14 -19
- data/lib/transferzero-sdk/models/payout_method_details.rb +398 -297
- data/lib/transferzero-sdk/models/payout_method_details_balance.rb +61 -60
- data/lib/transferzero-sdk/models/payout_method_details_btc.rb +250 -0
- data/lib/transferzero-sdk/models/payout_method_details_gbp_bank.rb +267 -0
- data/lib/transferzero-sdk/models/payout_method_details_ghs_bank.rb +97 -96
- data/lib/transferzero-sdk/models/payout_method_details_iban.rb +100 -104
- data/lib/transferzero-sdk/models/payout_method_details_mad_cash.rb +162 -161
- data/lib/transferzero-sdk/models/payout_method_details_mobile.rb +93 -83
- data/lib/transferzero-sdk/models/payout_method_details_ngn_bank.rb +104 -103
- data/lib/transferzero-sdk/models/payout_method_details_xof_bank.rb +108 -107
- data/lib/transferzero-sdk/models/payout_method_details_xof_mobile.rb +97 -96
- data/lib/transferzero-sdk/models/payout_method_details_zar_bank.rb +324 -0
- data/lib/transferzero-sdk/models/payout_method_gender_enum.rb +14 -19
- data/lib/transferzero-sdk/models/payout_method_identity_card_type_enum.rb +15 -20
- data/lib/transferzero-sdk/models/payout_method_list_response.rb +67 -66
- data/lib/transferzero-sdk/models/payout_method_mobile_provider_enum.rb +17 -19
- data/lib/transferzero-sdk/models/payout_method_request.rb +60 -59
- data/lib/transferzero-sdk/models/payout_method_response.rb +60 -59
- data/lib/transferzero-sdk/models/payout_method_webhook.rb +96 -95
- data/lib/transferzero-sdk/models/politically_exposed_person.rb +272 -0
- data/lib/transferzero-sdk/models/recipient.rb +230 -229
- data/lib/transferzero-sdk/models/recipient_list_response.rb +67 -66
- data/lib/transferzero-sdk/models/recipient_request.rb +60 -59
- data/lib/transferzero-sdk/models/recipient_response.rb +60 -59
- data/lib/transferzero-sdk/models/recipient_state.rb +22 -27
- data/lib/transferzero-sdk/models/recipient_webhook.rb +96 -95
- data/lib/transferzero-sdk/models/sender.rb +587 -348
- data/lib/transferzero-sdk/models/sender_list_response.rb +67 -66
- data/lib/transferzero-sdk/models/sender_request.rb +60 -59
- data/lib/transferzero-sdk/models/sender_response.rb +66 -65
- data/lib/transferzero-sdk/models/sender_response_existing.rb +60 -59
- data/lib/transferzero-sdk/models/sender_response_meta.rb +60 -59
- data/lib/transferzero-sdk/models/sender_state.rb +19 -24
- data/lib/transferzero-sdk/models/sender_webhook.rb +96 -95
- data/lib/transferzero-sdk/models/transaction.rb +192 -191
- data/lib/transferzero-sdk/models/transaction_list_response.rb +67 -66
- data/lib/transferzero-sdk/models/transaction_request.rb +60 -59
- data/lib/transferzero-sdk/models/transaction_response.rb +66 -65
- data/lib/transferzero-sdk/models/transaction_response_existing.rb +66 -65
- data/lib/transferzero-sdk/models/transaction_response_meta.rb +60 -59
- data/lib/transferzero-sdk/models/transaction_state.rb +23 -28
- data/lib/transferzero-sdk/models/transaction_traits.rb +71 -70
- data/lib/transferzero-sdk/models/transaction_webhook.rb +96 -95
- data/lib/transferzero-sdk/models/validation_error_description.rb +62 -61
- data/lib/transferzero-sdk/models/webhook.rb +92 -91
- data/lib/transferzero-sdk/models/webhook_definition.rb +107 -106
- data/lib/transferzero-sdk/models/webhook_definition_event_list_response.rb +61 -60
- data/lib/transferzero-sdk/models/webhook_definition_list_response.rb +67 -66
- data/lib/transferzero-sdk/models/webhook_definition_request.rb +60 -59
- data/lib/transferzero-sdk/models/webhook_definition_response.rb +60 -59
- data/lib/transferzero-sdk/models/webhook_log.rb +97 -96
- data/lib/transferzero-sdk/models/webhook_log_list_response.rb +70 -69
- data/lib/transferzero-sdk/models/webhook_log_metadata.rb +129 -128
- data/lib/transferzero-sdk/models/webhook_log_metadata_request.rb +80 -79
- data/lib/transferzero-sdk/models/webhook_log_metadata_response.rb +81 -80
- data/lib/transferzero-sdk/models/webhook_log_response.rb +60 -59
- data/lib/transferzero-sdk/version.rb +1 -1
- data/spec/models/payin_method_details_btc_spec.rb +41 -0
- data/spec/models/payout_method_details_btc_spec.rb +59 -0
- data/spec/models/payout_method_details_gbp_bank_spec.rb +77 -0
- data/spec/models/payout_method_details_zar_bank_spec.rb +89 -0
- data/spec/models/politically_exposed_person_spec.rb +83 -0
- metadata +32 -13
- data/transferzero-sdk-1.4.0.gem +0 -0
@@ -13,133 +13,133 @@ OpenAPI Generator version: 4.0.0-beta3
|
|
13
13
|
require 'date'
|
14
14
|
|
15
15
|
module TransferZero
|
16
|
-
|
17
|
-
|
18
|
-
|
16
|
+
# ```JSON \"details\": { \"first_name\": \"First\", \"last_name\": \"Last\", \"bank_code\": \"058\", \"bank_account\": \"123456789\", \"bank_account_type\": \"10\" # 10 for saving # 20 for current accounts } ``` The valid bank_code values are: - Access Bank: 044 - Diamond Bank: 063 - EcoBank: 050 - FCMB Bank: 214 - Fidelity Bank: 070 - First Bank of Nigeria: 011 - Guaranty Trust Bank : 058 - Heritage Bank: 030 - Jaiz Bank: 301 - Keystone: 082 - Mainstreet: 014 - Polaris Bank: 076 - Stanbic IBTC Bank: 039 - Sterling bank: 232 - Union Bank: 032 - United Bank for Africa: 033 - Unity Bank: 215 - Wema Bank: 035 - Zenith International: 057
|
17
|
+
class PayoutMethodDetailsNGNBank
|
18
|
+
attr_accessor :first_name
|
19
19
|
|
20
|
-
|
20
|
+
attr_accessor :last_name
|
21
21
|
|
22
|
-
|
22
|
+
attr_accessor :bank_code
|
23
23
|
|
24
|
-
|
24
|
+
attr_accessor :bank_account
|
25
25
|
|
26
|
-
|
26
|
+
attr_accessor :bank_account_type
|
27
27
|
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
# Attribute type mapping.
|
40
|
-
def self.openapi_types
|
41
|
-
{
|
42
|
-
:'first_name' => :'String',
|
43
|
-
:'last_name' => :'String',
|
44
|
-
:'bank_code' => :'String',
|
45
|
-
:'bank_account' => :'String',
|
46
|
-
:'bank_account_type' => :'PayoutMethodBankAccountTypeEnum'
|
47
|
-
}
|
48
|
-
end
|
49
|
-
|
50
|
-
# Initializes the object
|
51
|
-
# @param [Hash] attributes Model attributes in the form of hash
|
52
|
-
def initialize(attributes = {})
|
53
|
-
if (!attributes.is_a?(Hash))
|
54
|
-
fail ArgumentError, "The input argument (attributes) must be a hash in `TransferZero::PayoutMethodDetailsNGNBank` initialize method"
|
55
|
-
end
|
56
|
-
|
57
|
-
# check to see if the attribute exists and convert string to symbol for hash key
|
58
|
-
attributes = attributes.each_with_object({}) { |(k, v), h|
|
59
|
-
if (!self.class.attribute_map.key?(k.to_sym))
|
60
|
-
fail ArgumentError, "`#{k}` is not a valid attribute in `TransferZero::PayoutMethodDetailsNGNBank`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
61
|
-
end
|
62
|
-
h[k.to_sym] = v
|
63
|
-
}
|
64
|
-
|
65
|
-
if attributes.key?(:'first_name')
|
66
|
-
self.first_name = attributes[:'first_name']
|
67
|
-
end
|
28
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
29
|
+
def self.attribute_map
|
30
|
+
{
|
31
|
+
:'first_name' => :'first_name',
|
32
|
+
:'last_name' => :'last_name',
|
33
|
+
:'bank_code' => :'bank_code',
|
34
|
+
:'bank_account' => :'bank_account',
|
35
|
+
:'bank_account_type' => :'bank_account_type'
|
36
|
+
}
|
37
|
+
end
|
68
38
|
|
69
|
-
|
70
|
-
|
71
|
-
|
39
|
+
# Attribute type mapping.
|
40
|
+
def self.openapi_types
|
41
|
+
{
|
42
|
+
:'first_name' => :'String',
|
43
|
+
:'last_name' => :'String',
|
44
|
+
:'bank_code' => :'String',
|
45
|
+
:'bank_account' => :'String',
|
46
|
+
:'bank_account_type' => :'PayoutMethodBankAccountTypeEnum'
|
47
|
+
}
|
48
|
+
end
|
72
49
|
|
73
|
-
|
74
|
-
|
75
|
-
|
50
|
+
# Initializes the object
|
51
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
52
|
+
def initialize(attributes = {})
|
53
|
+
if (!attributes.is_a?(Hash))
|
54
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `TransferZero::PayoutMethodDetailsNGNBank` initialize method"
|
55
|
+
end
|
76
56
|
|
77
|
-
|
78
|
-
|
57
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
58
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
59
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
60
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `TransferZero::PayoutMethodDetailsNGNBank`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
79
61
|
end
|
62
|
+
h[k.to_sym] = v
|
63
|
+
}
|
80
64
|
|
81
|
-
|
82
|
-
|
83
|
-
end
|
65
|
+
if attributes.key?(:'first_name')
|
66
|
+
self.first_name = attributes[:'first_name']
|
84
67
|
end
|
85
68
|
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
invalid_properties = Array.new
|
90
|
-
if @first_name.nil?
|
91
|
-
invalid_properties.push('invalid value for "first_name", first_name cannot be nil.')
|
92
|
-
end
|
93
|
-
|
94
|
-
if @last_name.nil?
|
95
|
-
invalid_properties.push('invalid value for "last_name", last_name cannot be nil.')
|
96
|
-
end
|
69
|
+
if attributes.key?(:'last_name')
|
70
|
+
self.last_name = attributes[:'last_name']
|
71
|
+
end
|
97
72
|
|
98
|
-
|
99
|
-
|
100
|
-
|
73
|
+
if attributes.key?(:'bank_code')
|
74
|
+
self.bank_code = attributes[:'bank_code']
|
75
|
+
end
|
101
76
|
|
102
|
-
|
103
|
-
|
104
|
-
|
77
|
+
if attributes.key?(:'bank_account')
|
78
|
+
self.bank_account = attributes[:'bank_account']
|
79
|
+
end
|
105
80
|
|
106
|
-
|
81
|
+
if attributes.key?(:'bank_account_type')
|
82
|
+
self.bank_account_type = attributes[:'bank_account_type']
|
107
83
|
end
|
84
|
+
end
|
108
85
|
|
109
|
-
|
110
|
-
|
111
|
-
|
112
|
-
|
113
|
-
|
114
|
-
|
115
|
-
return false if @bank_account.nil?
|
116
|
-
true
|
86
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
87
|
+
# @return Array for valid properties with the reasons
|
88
|
+
def list_invalid_properties
|
89
|
+
invalid_properties = Array.new
|
90
|
+
if @first_name.nil?
|
91
|
+
invalid_properties.push('invalid value for "first_name", first_name cannot be nil.')
|
117
92
|
end
|
118
93
|
|
119
|
-
|
120
|
-
|
121
|
-
def ==(o)
|
122
|
-
return true if self.equal?(o)
|
123
|
-
self.class == o.class &&
|
124
|
-
first_name == o.first_name &&
|
125
|
-
last_name == o.last_name &&
|
126
|
-
bank_code == o.bank_code &&
|
127
|
-
bank_account == o.bank_account &&
|
128
|
-
bank_account_type == o.bank_account_type
|
94
|
+
if @last_name.nil?
|
95
|
+
invalid_properties.push('invalid value for "last_name", last_name cannot be nil.')
|
129
96
|
end
|
130
97
|
|
131
|
-
|
132
|
-
|
133
|
-
def eql?(o)
|
134
|
-
self == o
|
98
|
+
if @bank_code.nil?
|
99
|
+
invalid_properties.push('invalid value for "bank_code", bank_code cannot be nil.')
|
135
100
|
end
|
136
101
|
|
137
|
-
|
138
|
-
|
139
|
-
def hash
|
140
|
-
[first_name, last_name, bank_code, bank_account, bank_account_type].hash
|
102
|
+
if @bank_account.nil?
|
103
|
+
invalid_properties.push('invalid value for "bank_account", bank_account cannot be nil.')
|
141
104
|
end
|
142
105
|
|
106
|
+
invalid_properties
|
107
|
+
end
|
108
|
+
|
109
|
+
# Check to see if the all the properties in the model are valid
|
110
|
+
# @return true if the model is valid
|
111
|
+
def valid?
|
112
|
+
return false if @first_name.nil?
|
113
|
+
return false if @last_name.nil?
|
114
|
+
return false if @bank_code.nil?
|
115
|
+
return false if @bank_account.nil?
|
116
|
+
true
|
117
|
+
end
|
118
|
+
|
119
|
+
# Checks equality by comparing each attribute.
|
120
|
+
# @param [Object] Object to be compared
|
121
|
+
def ==(o)
|
122
|
+
return true if self.equal?(o)
|
123
|
+
self.class == o.class &&
|
124
|
+
first_name == o.first_name &&
|
125
|
+
last_name == o.last_name &&
|
126
|
+
bank_code == o.bank_code &&
|
127
|
+
bank_account == o.bank_account &&
|
128
|
+
bank_account_type == o.bank_account_type
|
129
|
+
end
|
130
|
+
|
131
|
+
# @see the `==` method
|
132
|
+
# @param [Object] Object to be compared
|
133
|
+
def eql?(o)
|
134
|
+
self == o
|
135
|
+
end
|
136
|
+
|
137
|
+
# Calculates hash code according to all attributes.
|
138
|
+
# @return [Integer] Hash code
|
139
|
+
def hash
|
140
|
+
[first_name, last_name, bank_code, bank_account, bank_account_type].hash
|
141
|
+
end
|
142
|
+
|
143
143
|
require 'active_support/core_ext/hash'
|
144
144
|
require 'active_support/hash_with_indifferent_access.rb'
|
145
145
|
# Builds the object from hash
|
@@ -254,5 +254,6 @@ def _to_hash(value)
|
|
254
254
|
end
|
255
255
|
end
|
256
256
|
|
257
|
-
|
257
|
+
end
|
258
|
+
|
258
259
|
end
|
@@ -13,138 +13,138 @@ OpenAPI Generator version: 4.0.0-beta3
|
|
13
13
|
require 'date'
|
14
14
|
|
15
15
|
module TransferZero
|
16
|
-
|
17
|
-
|
18
|
-
|
16
|
+
# ```JSON \"details\": { \"first_name\": \"First\", \"last_name\": \"Last\", \"iban\": \"SN08SN0000000000000000000000\", \"bank_name\": \"BRM\", \"bank_country\": \"SN\" # ISO country code for Senegal } ``` *** Currently in Beta phase ***
|
17
|
+
class PayoutMethodDetailsXOFBank
|
18
|
+
attr_accessor :first_name
|
19
19
|
|
20
|
-
|
20
|
+
attr_accessor :last_name
|
21
21
|
|
22
|
-
|
22
|
+
attr_accessor :iban
|
23
23
|
|
24
|
-
|
24
|
+
attr_accessor :bank_name
|
25
25
|
|
26
|
-
|
26
|
+
attr_accessor :bank_country
|
27
27
|
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
# Attribute type mapping.
|
40
|
-
def self.openapi_types
|
41
|
-
{
|
42
|
-
:'first_name' => :'String',
|
43
|
-
:'last_name' => :'String',
|
44
|
-
:'iban' => :'String',
|
45
|
-
:'bank_name' => :'String',
|
46
|
-
:'bank_country' => :'String'
|
47
|
-
}
|
48
|
-
end
|
49
|
-
|
50
|
-
# Initializes the object
|
51
|
-
# @param [Hash] attributes Model attributes in the form of hash
|
52
|
-
def initialize(attributes = {})
|
53
|
-
if (!attributes.is_a?(Hash))
|
54
|
-
fail ArgumentError, "The input argument (attributes) must be a hash in `TransferZero::PayoutMethodDetailsXOFBank` initialize method"
|
55
|
-
end
|
56
|
-
|
57
|
-
# check to see if the attribute exists and convert string to symbol for hash key
|
58
|
-
attributes = attributes.each_with_object({}) { |(k, v), h|
|
59
|
-
if (!self.class.attribute_map.key?(k.to_sym))
|
60
|
-
fail ArgumentError, "`#{k}` is not a valid attribute in `TransferZero::PayoutMethodDetailsXOFBank`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
61
|
-
end
|
62
|
-
h[k.to_sym] = v
|
63
|
-
}
|
64
|
-
|
65
|
-
if attributes.key?(:'first_name')
|
66
|
-
self.first_name = attributes[:'first_name']
|
67
|
-
end
|
28
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
29
|
+
def self.attribute_map
|
30
|
+
{
|
31
|
+
:'first_name' => :'first_name',
|
32
|
+
:'last_name' => :'last_name',
|
33
|
+
:'iban' => :'iban',
|
34
|
+
:'bank_name' => :'bank_name',
|
35
|
+
:'bank_country' => :'bank_country'
|
36
|
+
}
|
37
|
+
end
|
68
38
|
|
69
|
-
|
70
|
-
|
71
|
-
|
39
|
+
# Attribute type mapping.
|
40
|
+
def self.openapi_types
|
41
|
+
{
|
42
|
+
:'first_name' => :'String',
|
43
|
+
:'last_name' => :'String',
|
44
|
+
:'iban' => :'String',
|
45
|
+
:'bank_name' => :'String',
|
46
|
+
:'bank_country' => :'String'
|
47
|
+
}
|
48
|
+
end
|
72
49
|
|
73
|
-
|
74
|
-
|
75
|
-
|
50
|
+
# Initializes the object
|
51
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
52
|
+
def initialize(attributes = {})
|
53
|
+
if (!attributes.is_a?(Hash))
|
54
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `TransferZero::PayoutMethodDetailsXOFBank` initialize method"
|
55
|
+
end
|
76
56
|
|
77
|
-
|
78
|
-
|
57
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
58
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
59
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
60
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `TransferZero::PayoutMethodDetailsXOFBank`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
79
61
|
end
|
62
|
+
h[k.to_sym] = v
|
63
|
+
}
|
80
64
|
|
81
|
-
|
82
|
-
|
83
|
-
end
|
65
|
+
if attributes.key?(:'first_name')
|
66
|
+
self.first_name = attributes[:'first_name']
|
84
67
|
end
|
85
68
|
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
invalid_properties = Array.new
|
90
|
-
if @first_name.nil?
|
91
|
-
invalid_properties.push('invalid value for "first_name", first_name cannot be nil.')
|
92
|
-
end
|
93
|
-
|
94
|
-
if @last_name.nil?
|
95
|
-
invalid_properties.push('invalid value for "last_name", last_name cannot be nil.')
|
96
|
-
end
|
69
|
+
if attributes.key?(:'last_name')
|
70
|
+
self.last_name = attributes[:'last_name']
|
71
|
+
end
|
97
72
|
|
98
|
-
|
99
|
-
|
100
|
-
|
73
|
+
if attributes.key?(:'iban')
|
74
|
+
self.iban = attributes[:'iban']
|
75
|
+
end
|
101
76
|
|
102
|
-
|
103
|
-
|
104
|
-
|
77
|
+
if attributes.key?(:'bank_name')
|
78
|
+
self.bank_name = attributes[:'bank_name']
|
79
|
+
end
|
105
80
|
|
106
|
-
|
107
|
-
|
108
|
-
|
81
|
+
if attributes.key?(:'bank_country')
|
82
|
+
self.bank_country = attributes[:'bank_country']
|
83
|
+
end
|
84
|
+
end
|
109
85
|
|
110
|
-
|
86
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
87
|
+
# @return Array for valid properties with the reasons
|
88
|
+
def list_invalid_properties
|
89
|
+
invalid_properties = Array.new
|
90
|
+
if @first_name.nil?
|
91
|
+
invalid_properties.push('invalid value for "first_name", first_name cannot be nil.')
|
111
92
|
end
|
112
93
|
|
113
|
-
|
114
|
-
|
115
|
-
def valid?
|
116
|
-
return false if @first_name.nil?
|
117
|
-
return false if @last_name.nil?
|
118
|
-
return false if @iban.nil?
|
119
|
-
return false if @bank_name.nil?
|
120
|
-
return false if @bank_country.nil?
|
121
|
-
true
|
94
|
+
if @last_name.nil?
|
95
|
+
invalid_properties.push('invalid value for "last_name", last_name cannot be nil.')
|
122
96
|
end
|
123
97
|
|
124
|
-
|
125
|
-
|
126
|
-
def ==(o)
|
127
|
-
return true if self.equal?(o)
|
128
|
-
self.class == o.class &&
|
129
|
-
first_name == o.first_name &&
|
130
|
-
last_name == o.last_name &&
|
131
|
-
iban == o.iban &&
|
132
|
-
bank_name == o.bank_name &&
|
133
|
-
bank_country == o.bank_country
|
98
|
+
if @iban.nil?
|
99
|
+
invalid_properties.push('invalid value for "iban", iban cannot be nil.')
|
134
100
|
end
|
135
101
|
|
136
|
-
|
137
|
-
|
138
|
-
def eql?(o)
|
139
|
-
self == o
|
102
|
+
if @bank_name.nil?
|
103
|
+
invalid_properties.push('invalid value for "bank_name", bank_name cannot be nil.')
|
140
104
|
end
|
141
105
|
|
142
|
-
|
143
|
-
|
144
|
-
def hash
|
145
|
-
[first_name, last_name, iban, bank_name, bank_country].hash
|
106
|
+
if @bank_country.nil?
|
107
|
+
invalid_properties.push('invalid value for "bank_country", bank_country cannot be nil.')
|
146
108
|
end
|
147
109
|
|
110
|
+
invalid_properties
|
111
|
+
end
|
112
|
+
|
113
|
+
# Check to see if the all the properties in the model are valid
|
114
|
+
# @return true if the model is valid
|
115
|
+
def valid?
|
116
|
+
return false if @first_name.nil?
|
117
|
+
return false if @last_name.nil?
|
118
|
+
return false if @iban.nil?
|
119
|
+
return false if @bank_name.nil?
|
120
|
+
return false if @bank_country.nil?
|
121
|
+
true
|
122
|
+
end
|
123
|
+
|
124
|
+
# Checks equality by comparing each attribute.
|
125
|
+
# @param [Object] Object to be compared
|
126
|
+
def ==(o)
|
127
|
+
return true if self.equal?(o)
|
128
|
+
self.class == o.class &&
|
129
|
+
first_name == o.first_name &&
|
130
|
+
last_name == o.last_name &&
|
131
|
+
iban == o.iban &&
|
132
|
+
bank_name == o.bank_name &&
|
133
|
+
bank_country == o.bank_country
|
134
|
+
end
|
135
|
+
|
136
|
+
# @see the `==` method
|
137
|
+
# @param [Object] Object to be compared
|
138
|
+
def eql?(o)
|
139
|
+
self == o
|
140
|
+
end
|
141
|
+
|
142
|
+
# Calculates hash code according to all attributes.
|
143
|
+
# @return [Integer] Hash code
|
144
|
+
def hash
|
145
|
+
[first_name, last_name, iban, bank_name, bank_country].hash
|
146
|
+
end
|
147
|
+
|
148
148
|
require 'active_support/core_ext/hash'
|
149
149
|
require 'active_support/hash_with_indifferent_access.rb'
|
150
150
|
# Builds the object from hash
|
@@ -259,5 +259,6 @@ def _to_hash(value)
|
|
259
259
|
end
|
260
260
|
end
|
261
261
|
|
262
|
-
|
262
|
+
end
|
263
|
+
|
263
264
|
end
|