Class: Io::Flow::V0::Models::LogisticsSettings
- Inherits:
-
Object
- Object
- Io::Flow::V0::Models::LogisticsSettings
- Defined in:
- lib/flow_commerce/flow_api_v0_client.rb
Instance Attribute Summary collapse
-
#shipping_configuration ⇒ Object
readonly
Returns the value of attribute shipping_configuration.
Instance Method Summary collapse
- #copy(incoming = {}) ⇒ Object
-
#initialize(incoming = {}) ⇒ LogisticsSettings
constructor
A new instance of LogisticsSettings.
- #to_hash ⇒ Object
- #to_json ⇒ Object
Constructor Details
#initialize(incoming = {}) ⇒ LogisticsSettings
Returns a new instance of LogisticsSettings.
45902 45903 45904 45905 45906 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 45902 def initialize(incoming={}) opts = HttpClient::Helper.symbolize_keys(incoming) HttpClient::Preconditions.require_keys(opts, [:shipping_configuration], 'LogisticsSettings') @shipping_configuration = (x = opts.delete(:shipping_configuration); x.is_a?(::Io::Flow::V0::Models::ShippingConfigurationReference) ? x : ::Io::Flow::V0::Models::ShippingConfigurationReference.new(x)) end |
Instance Attribute Details
#shipping_configuration ⇒ Object (readonly)
Returns the value of attribute shipping_configuration.
45900 45901 45902 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 45900 def shipping_configuration @shipping_configuration end |
Instance Method Details
#copy(incoming = {}) ⇒ Object
45912 45913 45914 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 45912 def copy(incoming={}) LogisticsSettings.new(to_hash.merge(HttpClient::Helper.symbolize_keys(incoming))) end |
#to_hash ⇒ Object
45916 45917 45918 45919 45920 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 45916 def to_hash { :shipping_configuration => shipping_configuration.to_hash } end |
#to_json ⇒ Object
45908 45909 45910 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 45908 def to_json JSON.dump(to_hash) end |