class Cube

Attributes

height[RW]
length[RW]
width[RW]

Public Class Methods

new(length, width, height) click to toggle source
# File lib/roby/state/shapes.rb, line 20
def initialize(length, width, height)
    @length, @width, @height = length.to_f, width.to_f, height.to_f
end

Public Instance Methods

max_length(axis) click to toggle source
# File lib/roby/state/shapes.rb, line 24
def max_length(axis)
    if axis == :z
        [length, width].max
    else
        height
    end
end