Class: Io::Flow::V0::Models::CrossdockShipment
- Inherits:
-
Object
- Object
- Io::Flow::V0::Models::CrossdockShipment
- Defined in:
- lib/flow_commerce/flow_api_v0_client.rb
Instance Attribute Summary collapse
-
#center_id ⇒ Object
readonly
Returns the value of attribute center_id.
-
#order_number ⇒ Object
readonly
Returns the value of attribute order_number.
-
#partner_id ⇒ Object
readonly
Returns the value of attribute partner_id.
-
#status ⇒ Object
readonly
Returns the value of attribute status.
-
#tracking_id ⇒ Object
readonly
Returns the value of attribute tracking_id.
Instance Method Summary collapse
- #copy(incoming = {}) ⇒ Object
-
#initialize(incoming = {}) ⇒ CrossdockShipment
constructor
A new instance of CrossdockShipment.
- #to_hash ⇒ Object
- #to_json ⇒ Object
Constructor Details
#initialize(incoming = {}) ⇒ CrossdockShipment
Returns a new instance of CrossdockShipment.
37719 37720 37721 37722 37723 37724 37725 37726 37727 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 37719 def initialize(incoming={}) opts = HttpClient::Helper.symbolize_keys(incoming) HttpClient::Preconditions.require_keys(opts, [:partner_id, :center_id, :tracking_id, :order_number, :status], 'CrossdockShipment') @partner_id = HttpClient::Preconditions.assert_class('partner_id', opts.delete(:partner_id), String) @center_id = HttpClient::Preconditions.assert_class('center_id', opts.delete(:center_id), String) @tracking_id = HttpClient::Preconditions.assert_class('tracking_id', opts.delete(:tracking_id), String) @order_number = HttpClient::Preconditions.assert_class('order_number', opts.delete(:order_number), String) @status = HttpClient::Preconditions.assert_class('status', opts.delete(:status), String) end |
Instance Attribute Details
#center_id ⇒ Object (readonly)
Returns the value of attribute center_id.
37717 37718 37719 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 37717 def center_id @center_id end |
#order_number ⇒ Object (readonly)
Returns the value of attribute order_number.
37717 37718 37719 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 37717 def order_number @order_number end |
#partner_id ⇒ Object (readonly)
Returns the value of attribute partner_id.
37717 37718 37719 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 37717 def partner_id @partner_id end |
#status ⇒ Object (readonly)
Returns the value of attribute status.
37717 37718 37719 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 37717 def status @status end |
#tracking_id ⇒ Object (readonly)
Returns the value of attribute tracking_id.
37717 37718 37719 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 37717 def tracking_id @tracking_id end |
Instance Method Details
#copy(incoming = {}) ⇒ Object
37733 37734 37735 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 37733 def copy(incoming={}) CrossdockShipment.new(to_hash.merge(HttpClient::Helper.symbolize_keys(incoming))) end |
#to_hash ⇒ Object
37737 37738 37739 37740 37741 37742 37743 37744 37745 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 37737 def to_hash { :partner_id => partner_id, :center_id => center_id, :tracking_id => tracking_id, :order_number => order_number, :status => status } end |
#to_json ⇒ Object
37729 37730 37731 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 37729 def to_json JSON.dump(to_hash) end |