Class: Io::Flow::V0::Models::AbandonedOrderSettings
- Inherits:
-
Object
- Object
- Io::Flow::V0::Models::AbandonedOrderSettings
- Defined in:
- lib/flow_commerce/flow_api_v0_client.rb
Instance Attribute Summary collapse
-
#email_settings ⇒ Object
readonly
Returns the value of attribute email_settings.
-
#status ⇒ Object
readonly
Returns the value of attribute status.
Instance Method Summary collapse
- #copy(incoming = {}) ⇒ Object
-
#initialize(incoming = {}) ⇒ AbandonedOrderSettings
constructor
A new instance of AbandonedOrderSettings.
- #to_hash ⇒ Object
- #to_json ⇒ Object
Constructor Details
#initialize(incoming = {}) ⇒ AbandonedOrderSettings
Returns a new instance of AbandonedOrderSettings.
28816 28817 28818 28819 28820 28821 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 28816 def initialize(incoming={}) opts = HttpClient::Helper.symbolize_keys(incoming) HttpClient::Preconditions.require_keys(opts, [:email_settings, :status], 'AbandonedOrderSettings') @email_settings = (x = opts.delete(:email_settings); x.is_a?(::Io::Flow::V0::Models::AbandonedOrderEmailSettings) ? x : ::Io::Flow::V0::Models::AbandonedOrderEmailSettings.new(x)) @status = (x = opts.delete(:status); x.is_a?(::Io::Flow::V0::Models::AbandonedOrderSettingStatus) ? x : ::Io::Flow::V0::Models::AbandonedOrderSettingStatus.apply(x)) end |
Instance Attribute Details
#email_settings ⇒ Object (readonly)
Returns the value of attribute email_settings.
28814 28815 28816 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 28814 def email_settings @email_settings end |
#status ⇒ Object (readonly)
Returns the value of attribute status.
28814 28815 28816 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 28814 def status @status end |
Instance Method Details
#copy(incoming = {}) ⇒ Object
28827 28828 28829 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 28827 def copy(incoming={}) AbandonedOrderSettings.new(to_hash.merge(HttpClient::Helper.symbolize_keys(incoming))) end |
#to_hash ⇒ Object
28831 28832 28833 28834 28835 28836 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 28831 def to_hash { :email_settings => email_settings.to_hash, :status => status.value } end |
#to_json ⇒ Object
28823 28824 28825 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 28823 def to_json JSON.dump(to_hash) end |