class Ingenico::Connect::SDK::Domain::Payment::CardPaymentMethodSpecificInput
@attr [Ingenico::Connect::SDK::Domain::Definitions::Card] card @attr [Ingenico::Connect::SDK::Domain::Payment::ExternalCardholderAuthenticationData] external_cardholder_authentication_data
@attr [true/false] is_recurring
@attr [String] merchant_initiated_reason_indicator
@attr [String] return_url
@attr [Ingenico::Connect::SDK::Domain::Payment::ThreeDSecure] three_d_secure
Attributes
card[RW]
external_cardholder_authentication_data[RW]
@deprecated Use threeDSecure.externalCardholderAuthenticationData instead
is_recurring[RW]
merchant_initiated_reason_indicator[RW]
return_url[RW]
@deprecated Use threeDSecure.redirectionData.returnUrl instead
three_d_secure[RW]
Public Instance Methods
from_hash(hash)
click to toggle source
Calls superclass method
Ingenico::Connect::SDK::Domain::Payment::AbstractCardPaymentMethodSpecificInput#from_hash
# File lib/ingenico/connect/sdk/domain/payment/card_payment_method_specific_input.rb, line 50 def from_hash(hash) super if hash.has_key? 'card' raise TypeError, "value '%s' is not a Hash" % [hash['card']] unless hash['card'].is_a? Hash @card = Ingenico::Connect::SDK::Domain::Definitions::Card.new_from_hash(hash['card']) end if hash.has_key? 'externalCardholderAuthenticationData' raise TypeError, "value '%s' is not a Hash" % [hash['externalCardholderAuthenticationData']] unless hash['externalCardholderAuthenticationData'].is_a? Hash @external_cardholder_authentication_data = Ingenico::Connect::SDK::Domain::Payment::ExternalCardholderAuthenticationData.new_from_hash(hash['externalCardholderAuthenticationData']) end if hash.has_key? 'isRecurring' @is_recurring = hash['isRecurring'] end if hash.has_key? 'merchantInitiatedReasonIndicator' @merchant_initiated_reason_indicator = hash['merchantInitiatedReasonIndicator'] end if hash.has_key? 'returnUrl' @return_url = hash['returnUrl'] end if hash.has_key? 'threeDSecure' raise TypeError, "value '%s' is not a Hash" % [hash['threeDSecure']] unless hash['threeDSecure'].is_a? Hash @three_d_secure = Ingenico::Connect::SDK::Domain::Payment::ThreeDSecure.new_from_hash(hash['threeDSecure']) end end
to_h()
click to toggle source
@return (Hash)
Calls superclass method
Ingenico::Connect::SDK::Domain::Payment::AbstractCardPaymentMethodSpecificInput#to_h
# File lib/ingenico/connect/sdk/domain/payment/card_payment_method_specific_input.rb, line 39 def to_h hash = super hash['card'] = @card.to_h unless @card.nil? hash['externalCardholderAuthenticationData'] = @external_cardholder_authentication_data.to_h unless @external_cardholder_authentication_data.nil? hash['isRecurring'] = @is_recurring unless @is_recurring.nil? hash['merchantInitiatedReasonIndicator'] = @merchant_initiated_reason_indicator unless @merchant_initiated_reason_indicator.nil? hash['returnUrl'] = @return_url unless @return_url.nil? hash['threeDSecure'] = @three_d_secure.to_h unless @three_d_secure.nil? hash end