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.
11623 11624 11625 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 11623 def initialize(value) @value = HttpClient::Preconditions.assert_class('value', value, String) end |
Instance Attribute Details
#value ⇒ Object (readonly)
Returns the value of attribute value.
11621 11622 11623 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 11621 def value @value end |
Class Method Details
.ALL ⇒ Object
11643 11644 11645 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 11643 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
11628 11629 11630 11631 11632 11633 11634 11635 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 11628 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
11667 11668 11669 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 11667 def DeliveryOptionCostDetailComponentKey.center_commercial_invoice_fee @@_center_commercial_invoice_fee ||= DeliveryOptionCostDetailComponentKey.new('center_commercial_invoice_fee') end |
.center_inbound_carton_fee ⇒ Object
11671 11672 11673 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 11671 def DeliveryOptionCostDetailComponentKey.center_inbound_carton_fee @@_center_inbound_carton_fee ||= DeliveryOptionCostDetailComponentKey.new('center_inbound_carton_fee') end |
.center_outbound_carton_fee ⇒ Object
11675 11676 11677 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 11675 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
11638 11639 11640 11641 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 11638 def DeliveryOptionCostDetailComponentKey.from_string(value) HttpClient::Preconditions.assert_class('value', value, String) DeliveryOptionCostDetailComponentKey.ALL.find { |v| v.value == value } end |
.ratecard_base_cost ⇒ Object
11647 11648 11649 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 11647 def DeliveryOptionCostDetailComponentKey.ratecard_base_cost @@_ratecard_base_cost ||= DeliveryOptionCostDetailComponentKey.new('ratecard_base_cost') end |
.ratecard_ddp_fee ⇒ Object
11651 11652 11653 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 11651 def DeliveryOptionCostDetailComponentKey.ratecard_ddp_fee @@_ratecard_ddp_fee ||= DeliveryOptionCostDetailComponentKey.new('ratecard_ddp_fee') end |
.ratecard_fuel_surcharge ⇒ Object
11655 11656 11657 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 11655 def DeliveryOptionCostDetailComponentKey.ratecard_fuel_surcharge @@_ratecard_fuel_surcharge ||= DeliveryOptionCostDetailComponentKey.new('ratecard_fuel_surcharge') end |
.ratecard_oversized_shipment_fee ⇒ Object
11659 11660 11661 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 11659 def DeliveryOptionCostDetailComponentKey.ratecard_oversized_shipment_fee @@_ratecard_oversized_shipment_fee ||= DeliveryOptionCostDetailComponentKey.new('ratecard_oversized_shipment_fee') end |
.ratecard_rural_shipment_fee ⇒ Object
11663 11664 11665 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 11663 def DeliveryOptionCostDetailComponentKey.ratecard_rural_shipment_fee @@_ratecard_rural_shipment_fee ||= DeliveryOptionCostDetailComponentKey.new('ratecard_rural_shipment_fee') end |
Instance Method Details
#to_hash ⇒ Object
11679 11680 11681 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 11679 def to_hash value end |