Sha256: 8fafc453f3d8b0796b270df3503819557e6954ea05d26342edef91d7144f7f14

Contents?: true

Size: 377 Bytes

Versions: 6

Compression:

Stored size: 377 Bytes

Contents

# frozen_string_literal: true

module Physical
  class Item < Cuboid
    DEFAULT_LENGTH = 0

    attr_reader :cost,
                :sku,
                :description

    def initialize(**kwargs)
      @cost = Types::Money.optional[kwargs.delete(:cost)]
      @sku = kwargs.delete(:sku)
      @description = kwargs.delete(:description)
      super(**kwargs)
    end
  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
physical-0.5.1 lib/physical/item.rb
physical-0.5.0 lib/physical/item.rb
physical-0.4.9 lib/physical/item.rb
physical-0.4.8 lib/physical/item.rb
physical-0.4.7 lib/physical/item.rb
physical-0.4.5 lib/physical/item.rb