Class: Io::Flow::V0::Models::DeliveryOptionCostDetailComponentKey
- Inherits:
-
Object
- Object
- Io::Flow::V0::Models::DeliveryOptionCostDetailComponentKey
- Defined in:
- lib/flow_commerce/flow_api_v0_client.rb
Instance Attribute Summary collapse
-
#value ⇒ Object
readonly
Returns the value of attribute value.
Class Method Summary collapse
- .ALL ⇒ Object
-
.apply(value) ⇒ Object
Returns the instance of DeliveryOptionCostDetailComponentKey for this value, creating a new instance for an unknown value.
- .center_commercial_invoice_fee ⇒ Object
- .center_inbound_carton_fee ⇒ Object
- .center_outbound_carton_fee ⇒ Object
-
.from_string(value) ⇒ Object
Returns the instance of DeliveryOptionCostDetailComponentKey for this value, or nil if not found.
- .ratecard_base_cost ⇒ Object
- .ratecard_ddp_fee ⇒ Object
- .ratecard_fuel_surcharge ⇒ Object
- .ratecard_oversized_shipment_fee ⇒ Object
- .ratecard_rural_shipment_fee ⇒ Object
Instance Method Summary collapse
-
#initialize(value) ⇒ DeliveryOptionCostDetailComponentKey
constructor
A new instance of DeliveryOptionCostDetailComponentKey.
- #to_hash ⇒ Object
Constructor Details
#initialize(value) ⇒ DeliveryOptionCostDetailComponentKey
Returns a new instance of DeliveryOptionCostDetailComponentKey.
11374 11375 11376 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 11374 def initialize(value) @value = HttpClient::Preconditions.assert_class('value', value, String) end |
Instance Attribute Details
#value ⇒ Object (readonly)
Returns the value of attribute value.
11372 11373 11374 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 11372 def value @value end |
Class Method Details
.ALL ⇒ Object
11394 11395 11396 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 11394 def DeliveryOptionCostDetailComponentKey.ALL @@all ||= [DeliveryOptionCostDetailComponentKey.ratecard_base_cost, DeliveryOptionCostDetailComponentKey.ratecard_ddp_fee, DeliveryOptionCostDetailComponentKey.ratecard_fuel_surcharge, DeliveryOptionCostDetailComponentKey.ratecard_oversized_shipment_fee, DeliveryOptionCostDetailComponentKey.ratecard_rural_shipment_fee, DeliveryOptionCostDetailComponentKey.center_commercial_invoice_fee, DeliveryOptionCostDetailComponentKey.center_inbound_carton_fee, DeliveryOptionCostDetailComponentKey.center_outbound_carton_fee] end |
.apply(value) ⇒ Object
Returns the instance of DeliveryOptionCostDetailComponentKey for this value, creating a new instance for an unknown value
11379 11380 11381 11382 11383 11384 11385 11386 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 11379 def DeliveryOptionCostDetailComponentKey.apply(value) if value.instance_of?(DeliveryOptionCostDetailComponentKey) value else HttpClient::Preconditions.assert_class_or_nil('value', value, String) value.nil? ? nil : (from_string(value) || DeliveryOptionCostDetailComponentKey.new(value)) end end |
.center_commercial_invoice_fee ⇒ Object
11418 11419 11420 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 11418 def DeliveryOptionCostDetailComponentKey.center_commercial_invoice_fee @@_center_commercial_invoice_fee ||= DeliveryOptionCostDetailComponentKey.new('center_commercial_invoice_fee') end |
.center_inbound_carton_fee ⇒ Object
11422 11423 11424 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 11422 def DeliveryOptionCostDetailComponentKey.center_inbound_carton_fee @@_center_inbound_carton_fee ||= DeliveryOptionCostDetailComponentKey.new('center_inbound_carton_fee') end |
.center_outbound_carton_fee ⇒ Object
11426 11427 11428 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 11426 def DeliveryOptionCostDetailComponentKey.center_outbound_carton_fee @@_center_outbound_carton_fee ||= DeliveryOptionCostDetailComponentKey.new('center_outbound_carton_fee') end |
.from_string(value) ⇒ Object
Returns the instance of DeliveryOptionCostDetailComponentKey for this value, or nil if not found
11389 11390 11391 11392 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 11389 def DeliveryOptionCostDetailComponentKey.from_string(value) HttpClient::Preconditions.assert_class('value', value, String) DeliveryOptionCostDetailComponentKey.ALL.find { |v| v.value == value } end |
.ratecard_base_cost ⇒ Object
11398 11399 11400 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 11398 def DeliveryOptionCostDetailComponentKey.ratecard_base_cost @@_ratecard_base_cost ||= DeliveryOptionCostDetailComponentKey.new('ratecard_base_cost') end |
.ratecard_ddp_fee ⇒ Object
11402 11403 11404 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 11402 def DeliveryOptionCostDetailComponentKey.ratecard_ddp_fee @@_ratecard_ddp_fee ||= DeliveryOptionCostDetailComponentKey.new('ratecard_ddp_fee') end |
.ratecard_fuel_surcharge ⇒ Object
11406 11407 11408 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 11406 def DeliveryOptionCostDetailComponentKey.ratecard_fuel_surcharge @@_ratecard_fuel_surcharge ||= DeliveryOptionCostDetailComponentKey.new('ratecard_fuel_surcharge') end |
.ratecard_oversized_shipment_fee ⇒ Object
11410 11411 11412 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 11410 def DeliveryOptionCostDetailComponentKey.ratecard_oversized_shipment_fee @@_ratecard_oversized_shipment_fee ||= DeliveryOptionCostDetailComponentKey.new('ratecard_oversized_shipment_fee') end |
.ratecard_rural_shipment_fee ⇒ Object
11414 11415 11416 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 11414 def DeliveryOptionCostDetailComponentKey.ratecard_rural_shipment_fee @@_ratecard_rural_shipment_fee ||= DeliveryOptionCostDetailComponentKey.new('ratecard_rural_shipment_fee') end |
Instance Method Details
#to_hash ⇒ Object
11430 11431 11432 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 11430 def to_hash value end |