Class: FriendlyShipping::ItemOptions

Inherits:
Object
  • Object
show all
Defined in:
lib/friendly_shipping/item_options.rb

Overview

Base class for item options. Used when serializing API requests.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(item_id:) ⇒ ItemOptions

Returns a new instance of ItemOptions.

Parameters:

  • item_id (String)

    the ID for the item that belongs to these options



10
11
12
# File 'lib/friendly_shipping/item_options.rb', line 10

def initialize(item_id:)
  @item_id = item_id
end

Instance Attribute Details

#item_idString (readonly)

Returns the ID for the item that belongs to these options.

Returns:

  • (String)

    the ID for the item that belongs to these options



7
8
9
# File 'lib/friendly_shipping/item_options.rb', line 7

def item_id
  @item_id
end