Class: OnlinePayments::SDK::Domain::MerchantAction
- Inherits:
-
DataObject
- Object
- DataObject
- OnlinePayments::SDK::Domain::MerchantAction
- Defined in:
- lib/onlinepayments/sdk/domain/merchant_action.rb
Instance Attribute Summary collapse
-
#action_type ⇒ String
The current value of action_type.
-
#mobile_three_d_secure_challenge_parameters ⇒ OnlinePayments::SDK::Domain::MobileThreeDSecureChallengeParameters
The current value of mobile_three_d_secure_challenge_parameters.
-
#redirect_data ⇒ OnlinePayments::SDK::Domain::RedirectData
The current value of redirect_data.
-
#show_form_data ⇒ OnlinePayments::SDK::Domain::ShowFormData
The current value of show_form_data.
-
#show_instructions_data ⇒ OnlinePayments::SDK::Domain::ShowInstructionsData
The current value of show_instructions_data.
Instance Method Summary collapse
Methods inherited from DataObject
Instance Attribute Details
#action_type ⇒ String
Returns the current value of action_type.
18 19 20 |
# File 'lib/onlinepayments/sdk/domain/merchant_action.rb', line 18 def action_type @action_type end |
#mobile_three_d_secure_challenge_parameters ⇒ OnlinePayments::SDK::Domain::MobileThreeDSecureChallengeParameters
Returns the current value of mobile_three_d_secure_challenge_parameters.
18 19 20 |
# File 'lib/onlinepayments/sdk/domain/merchant_action.rb', line 18 def mobile_three_d_secure_challenge_parameters @mobile_three_d_secure_challenge_parameters end |
#redirect_data ⇒ OnlinePayments::SDK::Domain::RedirectData
Returns the current value of redirect_data.
18 19 20 |
# File 'lib/onlinepayments/sdk/domain/merchant_action.rb', line 18 def redirect_data @redirect_data end |
#show_form_data ⇒ OnlinePayments::SDK::Domain::ShowFormData
Returns the current value of show_form_data.
18 19 20 |
# File 'lib/onlinepayments/sdk/domain/merchant_action.rb', line 18 def show_form_data @show_form_data end |
#show_instructions_data ⇒ OnlinePayments::SDK::Domain::ShowInstructionsData
Returns the current value of show_instructions_data.
18 19 20 |
# File 'lib/onlinepayments/sdk/domain/merchant_action.rb', line 18 def show_instructions_data @show_instructions_data end |
Instance Method Details
#from_hash(hash) ⇒ Object
41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 |
# File 'lib/onlinepayments/sdk/domain/merchant_action.rb', line 41 def from_hash(hash) super if hash.has_key? 'actionType' @action_type = hash['actionType'] end if hash.has_key? 'mobileThreeDSecureChallengeParameters' raise TypeError, "value '%s' is not a Hash" % [hash['mobileThreeDSecureChallengeParameters']] unless hash['mobileThreeDSecureChallengeParameters'].is_a? Hash @mobile_three_d_secure_challenge_parameters = OnlinePayments::SDK::Domain::MobileThreeDSecureChallengeParameters.new_from_hash(hash['mobileThreeDSecureChallengeParameters']) end if hash.has_key? 'redirectData' raise TypeError, "value '%s' is not a Hash" % [hash['redirectData']] unless hash['redirectData'].is_a? Hash @redirect_data = OnlinePayments::SDK::Domain::RedirectData.new_from_hash(hash['redirectData']) end if hash.has_key? 'showFormData' raise TypeError, "value '%s' is not a Hash" % [hash['showFormData']] unless hash['showFormData'].is_a? Hash @show_form_data = OnlinePayments::SDK::Domain::ShowFormData.new_from_hash(hash['showFormData']) end if hash.has_key? 'showInstructionsData' raise TypeError, "value '%s' is not a Hash" % [hash['showInstructionsData']] unless hash['showInstructionsData'].is_a? Hash @show_instructions_data = OnlinePayments::SDK::Domain::ShowInstructionsData.new_from_hash(hash['showInstructionsData']) end end |
#to_h ⇒ Hash
31 32 33 34 35 36 37 38 39 |
# File 'lib/onlinepayments/sdk/domain/merchant_action.rb', line 31 def to_h hash = super hash['actionType'] = @action_type unless @action_type.nil? hash['mobileThreeDSecureChallengeParameters'] = @mobile_three_d_secure_challenge_parameters.to_h unless @mobile_three_d_secure_challenge_parameters.nil? hash['redirectData'] = @redirect_data.to_h unless @redirect_data.nil? hash['showFormData'] = @show_form_data.to_h unless @show_form_data.nil? hash['showInstructionsData'] = @show_instructions_data.to_h unless @show_instructions_data.nil? hash end |