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
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
16 17 18 |
# File 'lib/ingenico/connect/sdk/domain/payment/mobile_payment_method_specific_input.rb', line 16 def end |
#decrypted_payment_data ⇒ Object
19 20 21 |
# File 'lib/ingenico/connect/sdk/domain/payment/mobile_payment_method_specific_input.rb', line 19 def decrypted_payment_data @decrypted_payment_data end |
#encrypted_payment_data ⇒ Object
String
22 23 24 |
# File 'lib/ingenico/connect/sdk/domain/payment/mobile_payment_method_specific_input.rb', line 22 def encrypted_payment_data @encrypted_payment_data end |
#payment_product320_specific_input ⇒ Object
25 26 27 |
# File 'lib/ingenico/connect/sdk/domain/payment/mobile_payment_method_specific_input.rb', line 25 def payment_product320_specific_input @payment_product320_specific_input end |
#requires_approval ⇒ Object
true/false
28 29 30 |
# File 'lib/ingenico/connect/sdk/domain/payment/mobile_payment_method_specific_input.rb', line 28 def requires_approval @requires_approval end |
#skip_fraud_service ⇒ Object
true/false
31 32 33 |
# File 'lib/ingenico/connect/sdk/domain/payment/mobile_payment_method_specific_input.rb', line 31 def skip_fraud_service @skip_fraud_service end |
#transaction_id ⇒ Object
String
34 35 36 |
# File 'lib/ingenico/connect/sdk/domain/payment/mobile_payment_method_specific_input.rb', line 34 def transaction_id @transaction_id end |
Instance Method Details
#from_hash(hash) ⇒ Object
48 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 |
# File 'lib/ingenico/connect/sdk/domain/payment/mobile_payment_method_specific_input.rb', line 48 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
36 37 38 39 40 41 42 43 44 45 46 |
# File 'lib/ingenico/connect/sdk/domain/payment/mobile_payment_method_specific_input.rb', line 36 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 |