Class: Ingenico::Connect::SDK::Domain::Definitions::FraudFields
- Inherits:
-
Ingenico::Connect::SDK::DataObject
- Object
- Ingenico::Connect::SDK::DataObject
- Ingenico::Connect::SDK::Domain::Definitions::FraudFields
- Defined in:
- lib/ingenico/connect/sdk/domain/definitions/fraud_fields.rb
Instance Attribute Summary collapse
-
#addresses_are_identical ⇒ Object
true/false.
-
#black_list_data ⇒ Object
String.
- #card_owner_address ⇒ Object
-
#customer_ip_address ⇒ Object
String.
-
#default_form_fill ⇒ Object
String.
-
#device_fingerprint_activated ⇒ Object
true/false.
-
#device_fingerprint_transaction_id ⇒ Object
String.
-
#gift_card_type ⇒ Object
String.
-
#gift_message ⇒ Object
String.
-
#has_forgotten_pwd ⇒ Object
true/false.
-
#has_password ⇒ Object
true/false.
-
#is_previous_customer ⇒ Object
true/false.
-
#order_timezone ⇒ Object
String.
-
#ship_comments ⇒ Object
String.
-
#shipment_tracking_number ⇒ Object
String.
- #shipping_details ⇒ Object
-
#user_data ⇒ Object
Array of String.
-
#website ⇒ Object
String.
Instance Method Summary collapse
Methods inherited from Ingenico::Connect::SDK::DataObject
Instance Attribute Details
#addresses_are_identical ⇒ Object
true/false
16 17 18 |
# File 'lib/ingenico/connect/sdk/domain/definitions/fraud_fields.rb', line 16 def addresses_are_identical @addresses_are_identical end |
#black_list_data ⇒ Object
String
19 20 21 |
# File 'lib/ingenico/connect/sdk/domain/definitions/fraud_fields.rb', line 19 def black_list_data @black_list_data end |
#card_owner_address ⇒ Object
22 23 24 |
# File 'lib/ingenico/connect/sdk/domain/definitions/fraud_fields.rb', line 22 def card_owner_address @card_owner_address end |
#customer_ip_address ⇒ Object
String
25 26 27 |
# File 'lib/ingenico/connect/sdk/domain/definitions/fraud_fields.rb', line 25 def customer_ip_address @customer_ip_address end |
#default_form_fill ⇒ Object
String
28 29 30 |
# File 'lib/ingenico/connect/sdk/domain/definitions/fraud_fields.rb', line 28 def default_form_fill @default_form_fill end |
#device_fingerprint_activated ⇒ Object
true/false
31 32 33 |
# File 'lib/ingenico/connect/sdk/domain/definitions/fraud_fields.rb', line 31 def device_fingerprint_activated @device_fingerprint_activated end |
#device_fingerprint_transaction_id ⇒ Object
String
34 35 36 |
# File 'lib/ingenico/connect/sdk/domain/definitions/fraud_fields.rb', line 34 def device_fingerprint_transaction_id @device_fingerprint_transaction_id end |
#gift_card_type ⇒ Object
String
37 38 39 |
# File 'lib/ingenico/connect/sdk/domain/definitions/fraud_fields.rb', line 37 def gift_card_type @gift_card_type end |
#gift_message ⇒ Object
String
40 41 42 |
# File 'lib/ingenico/connect/sdk/domain/definitions/fraud_fields.rb', line 40 def @gift_message end |
#has_forgotten_pwd ⇒ Object
true/false
43 44 45 |
# File 'lib/ingenico/connect/sdk/domain/definitions/fraud_fields.rb', line 43 def has_forgotten_pwd @has_forgotten_pwd end |
#has_password ⇒ Object
true/false
46 47 48 |
# File 'lib/ingenico/connect/sdk/domain/definitions/fraud_fields.rb', line 46 def has_password @has_password end |
#is_previous_customer ⇒ Object
true/false
49 50 51 |
# File 'lib/ingenico/connect/sdk/domain/definitions/fraud_fields.rb', line 49 def is_previous_customer @is_previous_customer end |
#order_timezone ⇒ Object
String
52 53 54 |
# File 'lib/ingenico/connect/sdk/domain/definitions/fraud_fields.rb', line 52 def order_timezone @order_timezone end |
#ship_comments ⇒ Object
String
55 56 57 |
# File 'lib/ingenico/connect/sdk/domain/definitions/fraud_fields.rb', line 55 def ship_comments @ship_comments end |
#shipment_tracking_number ⇒ Object
String
58 59 60 |
# File 'lib/ingenico/connect/sdk/domain/definitions/fraud_fields.rb', line 58 def shipment_tracking_number @shipment_tracking_number end |
#shipping_details ⇒ Object
61 62 63 |
# File 'lib/ingenico/connect/sdk/domain/definitions/fraud_fields.rb', line 61 def shipping_details @shipping_details end |
#user_data ⇒ Object
Array of String
64 65 66 |
# File 'lib/ingenico/connect/sdk/domain/definitions/fraud_fields.rb', line 64 def user_data @user_data end |
#website ⇒ Object
String
67 68 69 |
# File 'lib/ingenico/connect/sdk/domain/definitions/fraud_fields.rb', line 67 def website @website end |
Instance Method Details
#from_hash(hash) ⇒ Object
92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 |
# File 'lib/ingenico/connect/sdk/domain/definitions/fraud_fields.rb', line 92 def from_hash(hash) super if hash.has_key?('addressesAreIdentical') @addresses_are_identical = hash['addressesAreIdentical'] end if hash.has_key?('blackListData') @black_list_data = hash['blackListData'] end if hash.has_key?('cardOwnerAddress') if !(hash['cardOwnerAddress'].is_a? Hash) raise TypeError, "value '%s' is not a Hash" % [hash['cardOwnerAddress']] end @card_owner_address = Ingenico::Connect::SDK::Domain::Definitions::Address.new_from_hash(hash['cardOwnerAddress']) end if hash.has_key?('customerIpAddress') @customer_ip_address = hash['customerIpAddress'] end if hash.has_key?('defaultFormFill') @default_form_fill = hash['defaultFormFill'] end if hash.has_key?('deviceFingerprintActivated') @device_fingerprint_activated = hash['deviceFingerprintActivated'] end if hash.has_key?('deviceFingerprintTransactionId') @device_fingerprint_transaction_id = hash['deviceFingerprintTransactionId'] end if hash.has_key?('giftCardType') @gift_card_type = hash['giftCardType'] end if hash.has_key?('giftMessage') @gift_message = hash['giftMessage'] end if hash.has_key?('hasForgottenPwd') @has_forgotten_pwd = hash['hasForgottenPwd'] end if hash.has_key?('hasPassword') @has_password = hash['hasPassword'] end if hash.has_key?('isPreviousCustomer') @is_previous_customer = hash['isPreviousCustomer'] end if hash.has_key?('orderTimezone') @order_timezone = hash['orderTimezone'] end if hash.has_key?('shipComments') @ship_comments = hash['shipComments'] end if hash.has_key?('shipmentTrackingNumber') @shipment_tracking_number = hash['shipmentTrackingNumber'] end if hash.has_key?('shippingDetails') if !(hash['shippingDetails'].is_a? Hash) raise TypeError, "value '%s' is not a Hash" % [hash['shippingDetails']] end @shipping_details = Ingenico::Connect::SDK::Domain::Definitions::FraudFieldsShippingDetails.new_from_hash(hash['shippingDetails']) end if hash.has_key?('userData') if !(hash['userData'].is_a? Array) raise TypeError, "value '%s' is not an Array" % [hash['userData']] end @user_data = [] hash['userData'].each do |e| @user_data << e end end if hash.has_key?('website') @website = hash['website'] end end |
#to_h ⇒ Object
69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 |
# File 'lib/ingenico/connect/sdk/domain/definitions/fraud_fields.rb', line 69 def to_h hash = super add_to_hash(hash, 'addressesAreIdentical', @addresses_are_identical) add_to_hash(hash, 'blackListData', @black_list_data) add_to_hash(hash, 'cardOwnerAddress', @card_owner_address) add_to_hash(hash, 'customerIpAddress', @customer_ip_address) add_to_hash(hash, 'defaultFormFill', @default_form_fill) add_to_hash(hash, 'deviceFingerprintActivated', @device_fingerprint_activated) add_to_hash(hash, 'deviceFingerprintTransactionId', @device_fingerprint_transaction_id) add_to_hash(hash, 'giftCardType', @gift_card_type) add_to_hash(hash, 'giftMessage', @gift_message) add_to_hash(hash, 'hasForgottenPwd', @has_forgotten_pwd) add_to_hash(hash, 'hasPassword', @has_password) add_to_hash(hash, 'isPreviousCustomer', @is_previous_customer) add_to_hash(hash, 'orderTimezone', @order_timezone) add_to_hash(hash, 'shipComments', @ship_comments) add_to_hash(hash, 'shipmentTrackingNumber', @shipment_tracking_number) add_to_hash(hash, 'shippingDetails', @shipping_details) add_to_hash(hash, 'userData', @user_data) add_to_hash(hash, 'website', @website) hash end |