Class: FriendlyShipping::Services::ShipEngine::RatesItemOptions
- Inherits:
-
ItemOptions
- Object
- ItemOptions
- FriendlyShipping::Services::ShipEngine::RatesItemOptions
- Defined in:
- lib/friendly_shipping/services/ship_engine/rates_item_options.rb
Overview
Options for each item passed in the rates API call.
Instance Attribute Summary collapse
-
#commodity_code ⇒ String
readonly
The HS or NMFC code for international shipments.
-
#country_of_origin ⇒ String
readonly
The country of origin for international shipments.
Attributes inherited from ItemOptions
Instance Method Summary collapse
-
#initialize(commodity_code: nil, country_of_origin: nil, **kwargs) ⇒ RatesItemOptions
constructor
A new instance of RatesItemOptions.
Constructor Details
#initialize(commodity_code: nil, country_of_origin: nil, **kwargs) ⇒ RatesItemOptions
Returns a new instance of RatesItemOptions.
18 19 20 21 22 |
# File 'lib/friendly_shipping/services/ship_engine/rates_item_options.rb', line 18 def initialize(commodity_code: nil, country_of_origin: nil, **kwargs) @commodity_code = commodity_code @country_of_origin = country_of_origin super(**kwargs) end |
Instance Attribute Details
#commodity_code ⇒ String (readonly)
Returns the HS or NMFC code for international shipments.
9 10 11 |
# File 'lib/friendly_shipping/services/ship_engine/rates_item_options.rb', line 9 def commodity_code @commodity_code end |
#country_of_origin ⇒ String (readonly)
Returns the country of origin for international shipments.
12 13 14 |
# File 'lib/friendly_shipping/services/ship_engine/rates_item_options.rb', line 12 def country_of_origin @country_of_origin end |