Class: OnlinePayments::SDK::Domain::RedirectPaymentProduct5407SpecificInput

Inherits:
DataObject
  • Object
show all
Defined in:
lib/onlinepayments/sdk/domain/redirect_payment_product5407_specific_input.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from DataObject

new_from_hash

Instance Attribute Details

#payment_product5704_auto_captureOnlinePayments::SDK::Domain::PaymentProduct5704AutoCapture

Returns the current value of payment_product5704_auto_capture.

Returns:



11
12
13
# File 'lib/onlinepayments/sdk/domain/redirect_payment_product5407_specific_input.rb', line 11

def payment_product5704_auto_capture
  @payment_product5704_auto_capture
end

Instance Method Details

#from_hash(hash) ⇒ Object



22
23
24
25
26
27
28
# File 'lib/onlinepayments/sdk/domain/redirect_payment_product5407_specific_input.rb', line 22

def from_hash(hash)
  super
  if hash.has_key? 'paymentProduct5704AutoCapture'
    raise TypeError, "value '%s' is not a Hash" % [hash['paymentProduct5704AutoCapture']] unless hash['paymentProduct5704AutoCapture'].is_a? Hash
    @payment_product5704_auto_capture = OnlinePayments::SDK::Domain::PaymentProduct5704AutoCapture.new_from_hash(hash['paymentProduct5704AutoCapture'])
  end
end

#to_hHash

Returns:

  • (Hash)


16
17
18
19
20
# File 'lib/onlinepayments/sdk/domain/redirect_payment_product5407_specific_input.rb', line 16

def to_h
  hash = super
  hash['paymentProduct5704AutoCapture'] = @payment_product5704_auto_capture.to_h unless @payment_product5704_auto_capture.nil?
  hash
end