Class: Worldline::Connect::SDK::V1::Domain::CreateHostedCheckoutResponse
- Inherits:
-
Domain::DataObject
- Object
- Domain::DataObject
- Worldline::Connect::SDK::V1::Domain::CreateHostedCheckoutResponse
- Defined in:
- lib/worldline/connect/sdk/v1/domain/create_hosted_checkout_response.rb
Instance Attribute Summary collapse
-
#hosted_checkout_id ⇒ String
The current value of hosted_checkout_id.
-
#invalid_tokens ⇒ Array<String>
The current value of invalid_tokens.
-
#merchant_reference ⇒ String
The current value of merchant_reference.
-
#partial_redirect_url ⇒ String
The current value of partial_redirect_url.
-
#returnmac ⇒ String
The current value of returnmac.
Instance Method Summary collapse
Methods inherited from Domain::DataObject
Instance Attribute Details
#hosted_checkout_id ⇒ String
Returns the current value of hosted_checkout_id.
17 18 19 |
# File 'lib/worldline/connect/sdk/v1/domain/create_hosted_checkout_response.rb', line 17 def hosted_checkout_id @hosted_checkout_id end |
#invalid_tokens ⇒ Array<String>
Returns the current value of invalid_tokens.
17 18 19 |
# File 'lib/worldline/connect/sdk/v1/domain/create_hosted_checkout_response.rb', line 17 def invalid_tokens @invalid_tokens end |
#merchant_reference ⇒ String
Returns the current value of merchant_reference.
17 18 19 |
# File 'lib/worldline/connect/sdk/v1/domain/create_hosted_checkout_response.rb', line 17 def merchant_reference @merchant_reference end |
#partial_redirect_url ⇒ String
Returns the current value of partial_redirect_url.
17 18 19 |
# File 'lib/worldline/connect/sdk/v1/domain/create_hosted_checkout_response.rb', line 17 def partial_redirect_url @partial_redirect_url end |
#returnmac ⇒ String
Returns the current value of returnmac.
17 18 19 |
# File 'lib/worldline/connect/sdk/v1/domain/create_hosted_checkout_response.rb', line 17 def returnmac @returnmac end |
Instance Method Details
#from_hash(hash) ⇒ Object
40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 |
# File 'lib/worldline/connect/sdk/v1/domain/create_hosted_checkout_response.rb', line 40 def from_hash(hash) super if hash.has_key? 'RETURNMAC' @returnmac = hash['RETURNMAC'] end if hash.has_key? 'hostedCheckoutId' @hosted_checkout_id = hash['hostedCheckoutId'] end if hash.has_key? 'invalidTokens' raise TypeError, "value '%s' is not an Array" % [hash['invalidTokens']] unless hash['invalidTokens'].is_a? Array @invalid_tokens = [] hash['invalidTokens'].each do |e| @invalid_tokens << e end end if hash.has_key? 'merchantReference' @merchant_reference = hash['merchantReference'] end if hash.has_key? 'partialRedirectUrl' @partial_redirect_url = hash['partialRedirectUrl'] end end |
#to_h ⇒ Hash
30 31 32 33 34 35 36 37 38 |
# File 'lib/worldline/connect/sdk/v1/domain/create_hosted_checkout_response.rb', line 30 def to_h hash = super hash['RETURNMAC'] = @returnmac unless @returnmac.nil? hash['hostedCheckoutId'] = @hosted_checkout_id unless @hosted_checkout_id.nil? hash['invalidTokens'] = @invalid_tokens unless @invalid_tokens.nil? hash['merchantReference'] = @merchant_reference unless @merchant_reference.nil? hash['partialRedirectUrl'] = @partial_redirect_url unless @partial_redirect_url.nil? hash end |