Class: OpenShip::Box

Inherits:
Object
  • Object
show all
Defined in:
lib/open-ship/sortr.rb

Direct Known Subclasses

Carton

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#heightObject

Returns the value of attribute height.



23
24
25
# File 'lib/open-ship/sortr.rb', line 23

def height
  @height
end

#labelObject

Returns the value of attribute label.



23
24
25
# File 'lib/open-ship/sortr.rb', line 23

def label
  @label
end

#lengthObject

Returns the value of attribute length.



23
24
25
# File 'lib/open-ship/sortr.rb', line 23

def length
  @length
end

#product_quantityObject

Returns the value of attribute product_quantity.



23
24
25
# File 'lib/open-ship/sortr.rb', line 23

def product_quantity
  @product_quantity
end

#weightObject

Returns the value of attribute weight.



23
24
25
# File 'lib/open-ship/sortr.rb', line 23

def weight
  @weight
end

#widthObject

Returns the value of attribute width.



23
24
25
# File 'lib/open-ship/sortr.rb', line 23

def width
  @width
end

Instance Method Details

#volumeObject



25
26
27
# File 'lib/open-ship/sortr.rb', line 25

def volume
  (length * width * height)
end