Class: Io::Flow::V0::Models::MerchantRejected
- Inherits:
-
OnboardingState
- Object
- OnboardingState
- Io::Flow::V0::Models::MerchantRejected
- Defined in:
- lib/flow_commerce/flow_api_v0_client.rb
Overview
The merchant is rejected for onboarding by the compliance team
Instance Attribute Summary collapse
-
#description ⇒ Object
readonly
Returns the value of attribute description.
-
#reason ⇒ Object
readonly
Returns the value of attribute reason.
Attributes inherited from OnboardingState
Instance Method Summary collapse
- #copy(incoming = {}) ⇒ Object
-
#initialize(incoming = {}) ⇒ MerchantRejected
constructor
A new instance of MerchantRejected.
- #subtype_to_hash ⇒ Object
- #to_json ⇒ Object
Methods inherited from OnboardingState
Constructor Details
#initialize(incoming = {}) ⇒ MerchantRejected
Returns a new instance of MerchantRejected.
50402 50403 50404 50405 50406 50407 50408 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 50402 def initialize(incoming={}) super(:discriminator => OnboardingState::Types::MERCHANT_REJECTED) opts = HttpClient::Helper.symbolize_keys(incoming) HttpClient::Preconditions.require_keys(opts, [:reason], 'MerchantRejected') @reason = (x = opts.delete(:reason); x.is_a?(::Io::Flow::V0::Models::MerchantRejectedReason) ? x : ::Io::Flow::V0::Models::MerchantRejectedReason.apply(x)) @description = (x = opts.delete(:description); x.nil? ? nil : HttpClient::Preconditions.assert_class('description', x, String)) end |
Instance Attribute Details
#description ⇒ Object (readonly)
Returns the value of attribute description.
50400 50401 50402 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 50400 def description @description end |
#reason ⇒ Object (readonly)
Returns the value of attribute reason.
50400 50401 50402 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 50400 def reason @reason end |
Instance Method Details
#copy(incoming = {}) ⇒ Object
50414 50415 50416 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 50414 def copy(incoming={}) MerchantRejected.new(subtype_to_hash.merge(HttpClient::Helper.symbolize_keys(incoming))) end |
#subtype_to_hash ⇒ Object
50418 50419 50420 50421 50422 50423 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 50418 def subtype_to_hash { :reason => reason.value, :description => description } end |
#to_json ⇒ Object
50410 50411 50412 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 50410 def to_json JSON.dump(to_hash) end |