Class: Io::Flow::V0::Models::ThreeDSecure
- Inherits:
-
Object
- Object
- Io::Flow::V0::Models::ThreeDSecure
- Defined in:
- lib/flow_commerce/flow_api_v0_client.rb
Overview
Represents the results from 3D Secure, if applied to an authorization
Instance Attribute Summary collapse
-
#code ⇒ Object
readonly
Returns the value of attribute code.
-
#description ⇒ Object
readonly
Returns the value of attribute description.
Instance Method Summary collapse
- #copy(incoming = {}) ⇒ Object
-
#initialize(incoming = {}) ⇒ ThreeDSecure
constructor
A new instance of ThreeDSecure.
- #to_hash ⇒ Object
- #to_json ⇒ Object
Constructor Details
#initialize(incoming = {}) ⇒ ThreeDSecure
Returns a new instance of ThreeDSecure.
52774 52775 52776 52777 52778 52779 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 52774 def initialize(incoming={}) opts = HttpClient::Helper.symbolize_keys(incoming) HttpClient::Preconditions.require_keys(opts, [:code], 'ThreeDSecure') @code = (x = opts.delete(:code); x.is_a?(::Io::Flow::V0::Models::ThreeDSecureCode) ? x : ::Io::Flow::V0::Models::ThreeDSecureCode.apply(x)) @description = (x = opts.delete(:description); x.nil? ? nil : HttpClient::Preconditions.assert_class('description', x, String)) end |
Instance Attribute Details
#code ⇒ Object (readonly)
Returns the value of attribute code.
52772 52773 52774 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 52772 def code @code end |
#description ⇒ Object (readonly)
Returns the value of attribute description.
52772 52773 52774 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 52772 def description @description end |
Instance Method Details
#copy(incoming = {}) ⇒ Object
52785 52786 52787 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 52785 def copy(incoming={}) ThreeDSecure.new(to_hash.merge(HttpClient::Helper.symbolize_keys(incoming))) end |
#to_hash ⇒ Object
52789 52790 52791 52792 52793 52794 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 52789 def to_hash { :code => code.value, :description => description } end |
#to_json ⇒ Object
52781 52782 52783 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 52781 def to_json JSON.dump(to_hash) end |