Class: Roby::Tools::Calculus::Unary

Inherits:
Struct
  • Object
show all
Includes:
Build
Defined in:
lib/roby/coordination/calculus.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Build

binary_op, unary_op

Instance Attribute Details

#opObject

Returns the value of attribute op

Returns:

  • (Object)

    the current value of op



27
28
29
# File 'lib/roby/coordination/calculus.rb', line 27

def op
  @op
end

#valObject

Returns the value of attribute val

Returns:

  • (Object)

    the current value of val



27
28
29
# File 'lib/roby/coordination/calculus.rb', line 27

def val
  @val
end

Instance Method Details

#evaluate(variables) ⇒ Object



28
29
30
# File 'lib/roby/coordination/calculus.rb', line 28

def evaluate(variables)
    val.evaluate(variables).send(op)
end