Class: Io::Flow::V0::Models::ExportLocalizedItemPrices
- Inherits:
-
Object
- Object
- Io::Flow::V0::Models::ExportLocalizedItemPrices
- Defined in:
- lib/flow_commerce/flow_api_v0_client.rb
Instance Attribute Summary collapse
-
#experience ⇒ Object
readonly
Returns the value of attribute experience.
-
#item ⇒ Object
readonly
Returns the value of attribute item.
-
#organization ⇒ Object
readonly
Returns the value of attribute organization.
-
#prices ⇒ Object
readonly
Returns the value of attribute prices.
Instance Method Summary collapse
- #copy(incoming = {}) ⇒ Object
-
#initialize(incoming = {}) ⇒ ExportLocalizedItemPrices
constructor
A new instance of ExportLocalizedItemPrices.
- #to_hash ⇒ Object
- #to_json ⇒ Object
Constructor Details
#initialize(incoming = {}) ⇒ ExportLocalizedItemPrices
18918 18919 18920 18921 18922 18923 18924 18925 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 18918 def initialize(incoming={}) opts = HttpClient::Helper.symbolize_keys(incoming) HttpClient::Preconditions.require_keys(opts, [:organization, :experience, :item, :prices], 'ExportLocalizedItemPrices') @organization = (x = opts.delete(:organization); x.is_a?(::Io::Flow::V0::Models::OrganizationReference) ? x : ::Io::Flow::V0::Models::OrganizationReference.new(x)) @experience = (x = opts.delete(:experience); x.is_a?(::Io::Flow::V0::Models::ExperienceReference) ? x : ::Io::Flow::V0::Models::ExperienceReference.new(x)) @item = (x = opts.delete(:item); x.is_a?(::Io::Flow::V0::Models::CatalogItemReference) ? x : ::Io::Flow::V0::Models::CatalogItemReference.new(x)) @prices = (x = opts.delete(:prices); x.is_a?(::Io::Flow::V0::Models::ExportLocalizedItemPricesDetail) ? x : ::Io::Flow::V0::Models::ExportLocalizedItemPricesDetail.new(x)) end |
Instance Attribute Details
#experience ⇒ Object (readonly)
Returns the value of attribute experience.
18916 18917 18918 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 18916 def experience @experience end |
#item ⇒ Object (readonly)
Returns the value of attribute item.
18916 18917 18918 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 18916 def item @item end |
#organization ⇒ Object (readonly)
Returns the value of attribute organization.
18916 18917 18918 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 18916 def organization @organization end |
#prices ⇒ Object (readonly)
Returns the value of attribute prices.
18916 18917 18918 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 18916 def prices @prices end |
Instance Method Details
#copy(incoming = {}) ⇒ Object
18931 18932 18933 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 18931 def copy(incoming={}) ExportLocalizedItemPrices.new(to_hash.merge(HttpClient::Helper.symbolize_keys(incoming))) end |
#to_hash ⇒ Object
18935 18936 18937 18938 18939 18940 18941 18942 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 18935 def to_hash { :organization => organization.to_hash, :experience => experience.to_hash, :item => item.to_hash, :prices => prices.to_hash } end |
#to_json ⇒ Object
18927 18928 18929 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 18927 def to_json JSON.dump(to_hash) end |