Class: Io::Flow::V0::Models::ExperienceLogisticsTierSummaryPrices

Inherits:
Object
  • Object
show all
Defined in:
lib/flow_commerce/flow_api_v0_client.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(incoming = {}) ⇒ ExperienceLogisticsTierSummaryPrices

Returns a new instance of ExperienceLogisticsTierSummaryPrices.



30948
30949
30950
30951
30952
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 30948

def initialize(incoming={})
  opts = HttpClient::Helper.symbolize_keys(incoming)
  HttpClient::Preconditions.require_keys(opts, [:minimum], 'ExperienceLogisticsTierSummaryPrices')
  @minimum = (x = opts.delete(:minimum); x.is_a?(::Io::Flow::V0::Models::Price) ? x : ::Io::Flow::V0::Models::Price.new(x))
end

Instance Attribute Details

#minimumObject (readonly)

Returns the value of attribute minimum.



30946
30947
30948
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 30946

def minimum
  @minimum
end

Instance Method Details

#copy(incoming = {}) ⇒ Object



30958
30959
30960
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 30958

def copy(incoming={})
  ExperienceLogisticsTierSummaryPrices.new(to_hash.merge(HttpClient::Helper.symbolize_keys(incoming)))
end

#to_hashObject



30962
30963
30964
30965
30966
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 30962

def to_hash
  {
    :minimum => minimum.to_hash
  }
end

#to_jsonObject



30954
30955
30956
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 30954

def to_json
  JSON.dump(to_hash)
end