class Ingenico::Direct::SDK::Domain::SepaDirectDebitPaymentMethodSpecificOutput
@attr [Ingenico::Direct::SDK::Domain::FraudResults] fraud_results
@attr [Ingenico::Direct::SDK::Domain::PaymentProduct771SpecificOutput] payment_product771_specific_output
@attr [Integer] payment_product_id
Attributes
fraud_results[RW]
payment_product771_specific_output[RW]
payment_product_id[RW]
Public Instance Methods
from_hash(hash)
click to toggle source
Calls superclass method
Ingenico::Direct::SDK::DataObject#from_hash
# File lib/ingenico/direct/sdk/domain/sepa_direct_debit_payment_method_specific_output.rb, line 29 def from_hash(hash) super if hash.key? 'fraudResults' raise TypeError, "value '%s' is not a Hash" % [hash['fraudResults']] unless hash['fraudResults'].is_a? Hash @fraud_results = Ingenico::Direct::SDK::Domain::FraudResults.new_from_hash(hash['fraudResults']) end if hash.key? 'paymentProduct771SpecificOutput' raise TypeError, "value '%s' is not a Hash" % [hash['paymentProduct771SpecificOutput']] unless hash['paymentProduct771SpecificOutput'].is_a? Hash @payment_product771_specific_output = Ingenico::Direct::SDK::Domain::PaymentProduct771SpecificOutput.new_from_hash(hash['paymentProduct771SpecificOutput']) end @payment_product_id = hash['paymentProductId'] if hash.key? 'paymentProductId' end
to_h()
click to toggle source
@return (Hash)
Calls superclass method
Ingenico::Direct::SDK::DataObject#to_h
# File lib/ingenico/direct/sdk/domain/sepa_direct_debit_payment_method_specific_output.rb, line 21 def to_h hash = super hash['fraudResults'] = @fraud_results.to_h if @fraud_results hash['paymentProduct771SpecificOutput'] = @payment_product771_specific_output.to_h if @payment_product771_specific_output hash['paymentProductId'] = @payment_product_id unless @payment_product_id.nil? hash end