Class: Ingenico::Connect::SDK::Domain::Payment::MobilePaymentMethodSpecificInput
- Inherits:
-
Definitions::AbstractPaymentMethodSpecificInput
- Object
- Ingenico::Connect::SDK::DataObject
- Definitions::AbstractPaymentMethodSpecificInput
- Ingenico::Connect::SDK::Domain::Payment::MobilePaymentMethodSpecificInput
- Defined in:
- lib/ingenico/connect/sdk/domain/payment/mobile_payment_method_specific_input.rb
Overview
Instance Attribute Summary collapse
-
#authorization_mode ⇒ Object
String.
- #decrypted_payment_data ⇒ Object
-
#encrypted_payment_data ⇒ Object
String.
- #payment_product320_specific_input ⇒ Object
-
#requires_approval ⇒ Object
true/false.
-
#skip_fraud_service ⇒ Object
true/false.
-
#transaction_id ⇒ Object
String.
Attributes inherited from Definitions::AbstractPaymentMethodSpecificInput
Instance Method Summary collapse
Methods inherited from Ingenico::Connect::SDK::DataObject
Instance Attribute Details
#authorization_mode ⇒ Object
String
17 18 19 |
# File 'lib/ingenico/connect/sdk/domain/payment/mobile_payment_method_specific_input.rb', line 17 def end |
#decrypted_payment_data ⇒ Object
20 21 22 |
# File 'lib/ingenico/connect/sdk/domain/payment/mobile_payment_method_specific_input.rb', line 20 def decrypted_payment_data @decrypted_payment_data end |
#encrypted_payment_data ⇒ Object
String
23 24 25 |
# File 'lib/ingenico/connect/sdk/domain/payment/mobile_payment_method_specific_input.rb', line 23 def encrypted_payment_data @encrypted_payment_data end |
#payment_product320_specific_input ⇒ Object
26 27 28 |
# File 'lib/ingenico/connect/sdk/domain/payment/mobile_payment_method_specific_input.rb', line 26 def payment_product320_specific_input @payment_product320_specific_input end |
#requires_approval ⇒ Object
true/false
29 30 31 |
# File 'lib/ingenico/connect/sdk/domain/payment/mobile_payment_method_specific_input.rb', line 29 def requires_approval @requires_approval end |
#skip_fraud_service ⇒ Object
true/false
32 33 34 |
# File 'lib/ingenico/connect/sdk/domain/payment/mobile_payment_method_specific_input.rb', line 32 def skip_fraud_service @skip_fraud_service end |
#transaction_id ⇒ Object
String
35 36 37 |
# File 'lib/ingenico/connect/sdk/domain/payment/mobile_payment_method_specific_input.rb', line 35 def transaction_id @transaction_id end |
Instance Method Details
#from_hash(hash) ⇒ Object
49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 |
# File 'lib/ingenico/connect/sdk/domain/payment/mobile_payment_method_specific_input.rb', line 49 def from_hash(hash) super if hash.has_key?('authorizationMode') = hash['authorizationMode'] end if hash.has_key?('decryptedPaymentData') if !(hash['decryptedPaymentData'].is_a? Hash) raise TypeError, "value '%s' is not a Hash" % [hash['decryptedPaymentData']] end @decrypted_payment_data = Ingenico::Connect::SDK::Domain::Payment::DecryptedPaymentData.new_from_hash(hash['decryptedPaymentData']) end if hash.has_key?('encryptedPaymentData') @encrypted_payment_data = hash['encryptedPaymentData'] end if hash.has_key?('paymentProduct320SpecificInput') if !(hash['paymentProduct320SpecificInput'].is_a? Hash) raise TypeError, "value '%s' is not a Hash" % [hash['paymentProduct320SpecificInput']] end @payment_product320_specific_input = Ingenico::Connect::SDK::Domain::Payment::MobilePaymentProduct320SpecificInput.new_from_hash(hash['paymentProduct320SpecificInput']) end if hash.has_key?('requiresApproval') @requires_approval = hash['requiresApproval'] end if hash.has_key?('skipFraudService') @skip_fraud_service = hash['skipFraudService'] end if hash.has_key?('transactionId') @transaction_id = hash['transactionId'] end end |
#to_h ⇒ Object
37 38 39 40 41 42 43 44 45 46 47 |
# File 'lib/ingenico/connect/sdk/domain/payment/mobile_payment_method_specific_input.rb', line 37 def to_h hash = super add_to_hash(hash, 'authorizationMode', ) add_to_hash(hash, 'decryptedPaymentData', @decrypted_payment_data) add_to_hash(hash, 'encryptedPaymentData', @encrypted_payment_data) add_to_hash(hash, 'paymentProduct320SpecificInput', @payment_product320_specific_input) add_to_hash(hash, 'requiresApproval', @requires_approval) add_to_hash(hash, 'skipFraudService', @skip_fraud_service) add_to_hash(hash, 'transactionId', @transaction_id) hash end |