Class: Io::Flow::V0::Models::AuthorizationResultActionNative
- Inherits:
-
AuthorizationResultAction
- Object
- AuthorizationResultAction
- Io::Flow::V0::Models::AuthorizationResultActionNative
- Defined in:
- lib/flow_commerce/flow_api_v0_client.rb
Overview
Provides details for how to acquire additional information from the customer natively in the browser (e.g. for 3D Secure 2).
Instance Attribute Summary collapse
-
#authorization ⇒ Object
readonly
Returns the value of attribute authorization.
-
#details ⇒ Object
readonly
Returns the value of attribute details.
-
#type ⇒ Object
readonly
Returns the value of attribute type.
Attributes inherited from AuthorizationResultAction
Instance Method Summary collapse
- #copy(incoming = {}) ⇒ Object
-
#initialize(incoming = {}) ⇒ AuthorizationResultActionNative
constructor
A new instance of AuthorizationResultActionNative.
- #subtype_to_hash ⇒ Object
- #to_json ⇒ Object
Methods inherited from AuthorizationResultAction
Constructor Details
#initialize(incoming = {}) ⇒ AuthorizationResultActionNative
Returns a new instance of AuthorizationResultActionNative.
31323 31324 31325 31326 31327 31328 31329 31330 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 31323 def initialize(incoming={}) super(:discriminator => AuthorizationResultAction::Types::AUTHORIZATION_RESULT_ACTION_NATIVE) opts = HttpClient::Helper.symbolize_keys(incoming) HttpClient::Preconditions.require_keys(opts, [:type, :authorization], 'AuthorizationResultActionNative') @type = (x = opts.delete(:type); x.is_a?(::Io::Flow::V0::Models::AuthorizationResultActionType) ? x : ::Io::Flow::V0::Models::AuthorizationResultActionType.apply(x)) @authorization = (x = opts.delete(:authorization); x.is_a?(::Io::Flow::V0::Models::AuthorizationReference) ? x : ::Io::Flow::V0::Models::AuthorizationReference.new(x)) @details = (x = opts.delete(:details); x.nil? ? nil : (x = x; x.is_a?(::Io::Flow::V0::Models::AuthorizationResultActionDetails) ? x : ::Io::Flow::V0::Models::AuthorizationResultActionDetails.from_json(x))) end |
Instance Attribute Details
#authorization ⇒ Object (readonly)
Returns the value of attribute authorization.
31321 31322 31323 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 31321 def @authorization end |
#details ⇒ Object (readonly)
Returns the value of attribute details.
31321 31322 31323 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 31321 def details @details end |
#type ⇒ Object (readonly)
Returns the value of attribute type.
31321 31322 31323 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 31321 def type @type end |
Instance Method Details
#copy(incoming = {}) ⇒ Object
31336 31337 31338 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 31336 def copy(incoming={}) AuthorizationResultActionNative.new(subtype_to_hash.merge(HttpClient::Helper.symbolize_keys(incoming))) end |
#subtype_to_hash ⇒ Object
31340 31341 31342 31343 31344 31345 31346 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 31340 def subtype_to_hash { :type => type.value, :authorization => .to_hash, :details => details.nil? ? nil : details.to_hash } end |
#to_json ⇒ Object
31332 31333 31334 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 31332 def to_json JSON.dump(to_hash) end |