Class: Io::Flow::V0::Models::SetupBlocked
- Inherits:
-
OnboardingState
- Object
- OnboardingState
- Io::Flow::V0::Models::SetupBlocked
- Defined in:
- lib/flow_commerce/flow_api_v0_client.rb
Overview
The onboarding process is blocked by an issue that requires escalation
Instance Attribute Summary collapse
-
#reasons ⇒ Object
readonly
Returns the value of attribute reasons.
Attributes inherited from OnboardingState
Instance Method Summary collapse
- #copy(incoming = {}) ⇒ Object
-
#initialize(incoming = {}) ⇒ SetupBlocked
constructor
A new instance of SetupBlocked.
- #subtype_to_hash ⇒ Object
- #to_json ⇒ Object
Methods inherited from OnboardingState
Constructor Details
#initialize(incoming = {}) ⇒ SetupBlocked
Returns a new instance of SetupBlocked.
65763 65764 65765 65766 65767 65768 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 65763 def initialize(incoming={}) super(:discriminator => OnboardingState::Types::SETUP_BLOCKED) opts = HttpClient::Helper.symbolize_keys(incoming) HttpClient::Preconditions.require_keys(opts, [:reasons], 'SetupBlocked') @reasons = HttpClient::Preconditions.assert_class('reasons', opts.delete(:reasons), Array).map { |v| (x = v; x.is_a?(::Io::Flow::V0::Models::OnboardingBlockedReason) ? x : ::Io::Flow::V0::Models::OnboardingBlockedReason.apply(x)) } end |
Instance Attribute Details
#reasons ⇒ Object (readonly)
Returns the value of attribute reasons.
65761 65762 65763 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 65761 def reasons @reasons end |
Instance Method Details
#copy(incoming = {}) ⇒ Object
65774 65775 65776 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 65774 def copy(incoming={}) SetupBlocked.new(subtype_to_hash.merge(HttpClient::Helper.symbolize_keys(incoming))) end |
#subtype_to_hash ⇒ Object
65778 65779 65780 65781 65782 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 65778 def subtype_to_hash { :reasons => reasons.map { |o| o.value } } end |
#to_json ⇒ Object
65770 65771 65772 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 65770 def to_json JSON.dump(to_hash) end |