Class: Io::Flow::V0::Models::OrganizationOnboardingStateUpserted
- Defined in:
- lib/flow_commerce/flow_api_v0_client.rb
Instance Attribute Summary collapse
-
#event_id ⇒ Object
readonly
Returns the value of attribute event_id.
-
#organization ⇒ Object
readonly
Returns the value of attribute organization.
-
#organization_onboarding_state ⇒ Object
readonly
Returns the value of attribute organization_onboarding_state.
-
#timestamp ⇒ Object
readonly
Returns the value of attribute timestamp.
Attributes inherited from Event
Instance Method Summary collapse
- #copy(incoming = {}) ⇒ Object
-
#initialize(incoming = {}) ⇒ OrganizationOnboardingStateUpserted
constructor
A new instance of OrganizationOnboardingStateUpserted.
- #subtype_to_hash ⇒ Object
- #to_json ⇒ Object
Methods inherited from Event
Constructor Details
#initialize(incoming = {}) ⇒ OrganizationOnboardingStateUpserted
Returns a new instance of OrganizationOnboardingStateUpserted.
55113 55114 55115 55116 55117 55118 55119 55120 55121 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 55113 def initialize(incoming={}) super(:discriminator => Event::Types::ORGANIZATION_ONBOARDING_STATE_UPSERTED) opts = HttpClient::Helper.symbolize_keys(incoming) HttpClient::Preconditions.require_keys(opts, [:event_id, :timestamp, :organization, :organization_onboarding_state], 'OrganizationOnboardingStateUpserted') @event_id = HttpClient::Preconditions.assert_class('event_id', opts.delete(:event_id), String) @timestamp = HttpClient::Preconditions.assert_class('timestamp', HttpClient::Helper.to_date_time_iso8601(opts.delete(:timestamp)), DateTime) @organization = HttpClient::Preconditions.assert_class('organization', opts.delete(:organization), String) @organization_onboarding_state = (x = opts.delete(:organization_onboarding_state); x.is_a?(::Io::Flow::V0::Models::OrganizationOnboardingState) ? x : ::Io::Flow::V0::Models::OrganizationOnboardingState.new(x)) end |
Instance Attribute Details
#event_id ⇒ Object (readonly)
Returns the value of attribute event_id.
55111 55112 55113 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 55111 def event_id @event_id end |
#organization ⇒ Object (readonly)
Returns the value of attribute organization.
55111 55112 55113 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 55111 def organization @organization end |
#organization_onboarding_state ⇒ Object (readonly)
Returns the value of attribute organization_onboarding_state.
55111 55112 55113 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 55111 def organization_onboarding_state @organization_onboarding_state end |
#timestamp ⇒ Object (readonly)
Returns the value of attribute timestamp.
55111 55112 55113 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 55111 def @timestamp end |
Instance Method Details
#copy(incoming = {}) ⇒ Object
55127 55128 55129 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 55127 def copy(incoming={}) OrganizationOnboardingStateUpserted.new(subtype_to_hash.merge(HttpClient::Helper.symbolize_keys(incoming))) end |
#subtype_to_hash ⇒ Object
55131 55132 55133 55134 55135 55136 55137 55138 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 55131 def subtype_to_hash { :event_id => event_id, :timestamp => , :organization => organization, :organization_onboarding_state => organization_onboarding_state.to_hash } end |
#to_json ⇒ Object
55123 55124 55125 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 55123 def to_json JSON.dump(to_hash) end |