Class: Io::Flow::V0::Models::OrderBuilderSelectionsForm
- Inherits:
-
Object
- Object
- Io::Flow::V0::Models::OrderBuilderSelectionsForm
- Defined in:
- lib/flow_commerce/flow_api_v0_client.rb
Instance Attribute Summary collapse
-
#selections ⇒ Object
readonly
Returns the value of attribute selections.
Instance Method Summary collapse
- #copy(incoming = {}) ⇒ Object
-
#initialize(incoming = {}) ⇒ OrderBuilderSelectionsForm
constructor
A new instance of OrderBuilderSelectionsForm.
- #to_hash ⇒ Object
- #to_json ⇒ Object
Constructor Details
#initialize(incoming = {}) ⇒ OrderBuilderSelectionsForm
Returns a new instance of OrderBuilderSelectionsForm.
45549 45550 45551 45552 45553 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 45549 def initialize(incoming={}) opts = HttpClient::Helper.symbolize_keys(incoming) HttpClient::Preconditions.require_keys(opts, [:selections], 'OrderBuilderSelectionsForm') @selections = HttpClient::Preconditions.assert_class('selections', opts.delete(:selections), Array).map { |v| HttpClient::Preconditions.assert_class('selections', v, String) } end |
Instance Attribute Details
#selections ⇒ Object (readonly)
Returns the value of attribute selections.
45547 45548 45549 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 45547 def selections @selections end |
Instance Method Details
#copy(incoming = {}) ⇒ Object
45559 45560 45561 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 45559 def copy(incoming={}) OrderBuilderSelectionsForm.new(to_hash.merge(HttpClient::Helper.symbolize_keys(incoming))) end |
#to_hash ⇒ Object
45563 45564 45565 45566 45567 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 45563 def to_hash { :selections => selections } end |
#to_json ⇒ Object
45555 45556 45557 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 45555 def to_json JSON.dump(to_hash) end |