Class: Ingenico::Connect::SDK::Domain::Payment::MobilePaymentMethodSpecificOutput
- Inherits:
-
AbstractPaymentMethodSpecificOutput
- Object
- Ingenico::Connect::SDK::DataObject
- AbstractPaymentMethodSpecificOutput
- Ingenico::Connect::SDK::Domain::Payment::MobilePaymentMethodSpecificOutput
- Defined in:
- lib/ingenico/connect/sdk/domain/payment/mobile_payment_method_specific_output.rb
Overview
Instance Attribute Summary collapse
-
#authorisation_code ⇒ Object
String.
- #fraud_results ⇒ Object
-
#network ⇒ Object
String.
- #payment_data ⇒ Object
- #three_d_secure_results ⇒ Object
Attributes inherited from AbstractPaymentMethodSpecificOutput
Instance Method Summary collapse
Methods inherited from Ingenico::Connect::SDK::DataObject
Instance Attribute Details
#authorisation_code ⇒ Object
String
18 19 20 |
# File 'lib/ingenico/connect/sdk/domain/payment/mobile_payment_method_specific_output.rb', line 18 def @authorisation_code end |
#fraud_results ⇒ Object
21 22 23 |
# File 'lib/ingenico/connect/sdk/domain/payment/mobile_payment_method_specific_output.rb', line 21 def fraud_results @fraud_results end |
#network ⇒ Object
String
24 25 26 |
# File 'lib/ingenico/connect/sdk/domain/payment/mobile_payment_method_specific_output.rb', line 24 def network @network end |
#payment_data ⇒ Object
27 28 29 |
# File 'lib/ingenico/connect/sdk/domain/payment/mobile_payment_method_specific_output.rb', line 27 def payment_data @payment_data end |
#three_d_secure_results ⇒ Object
30 31 32 |
# File 'lib/ingenico/connect/sdk/domain/payment/mobile_payment_method_specific_output.rb', line 30 def three_d_secure_results @three_d_secure_results end |
Instance Method Details
#from_hash(hash) ⇒ Object
42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 |
# File 'lib/ingenico/connect/sdk/domain/payment/mobile_payment_method_specific_output.rb', line 42 def from_hash(hash) super if hash.has_key?('authorisationCode') @authorisation_code = hash['authorisationCode'] end if hash.has_key?('fraudResults') if !(hash['fraudResults'].is_a? Hash) raise TypeError, "value '%s' is not a Hash" % [hash['fraudResults']] end @fraud_results = Ingenico::Connect::SDK::Domain::Definitions::CardFraudResults.new_from_hash(hash['fraudResults']) end if hash.has_key?('network') @network = hash['network'] end if hash.has_key?('paymentData') if !(hash['paymentData'].is_a? Hash) raise TypeError, "value '%s' is not a Hash" % [hash['paymentData']] end @payment_data = Ingenico::Connect::SDK::Domain::Payment::MobilePaymentData.new_from_hash(hash['paymentData']) end if hash.has_key?('threeDSecureResults') if !(hash['threeDSecureResults'].is_a? Hash) raise TypeError, "value '%s' is not a Hash" % [hash['threeDSecureResults']] end @three_d_secure_results = Ingenico::Connect::SDK::Domain::Payment::ThreeDSecureResults.new_from_hash(hash['threeDSecureResults']) end end |
#to_h ⇒ Object
32 33 34 35 36 37 38 39 40 |
# File 'lib/ingenico/connect/sdk/domain/payment/mobile_payment_method_specific_output.rb', line 32 def to_h hash = super add_to_hash(hash, 'authorisationCode', @authorisation_code) add_to_hash(hash, 'fraudResults', @fraud_results) add_to_hash(hash, 'network', @network) add_to_hash(hash, 'paymentData', @payment_data) add_to_hash(hash, 'threeDSecureResults', @three_d_secure_results) hash end |