Class: Control
- Inherits:
-
Reflection
- Object
- Reflection
- Control
- Defined in:
- lib/Control.rb
Constant Summary
Constants inherited from Reflection
Reflection::COUNT, Reflection::FAIL, Reflection::INPUT, Reflection::MESSAGE, Reflection::OUTPUT, Reflection::PASS, Reflection::STATUS, Reflection::TIME, Reflection::TYPE, Reflection::VALUE
Instance Attribute Summary
Attributes inherited from Reflection
Instance Method Summary collapse
-
#reflect(*args) ⇒ Object
Reflect on a method.
Methods inherited from Reflection
#initialize, #normalize_input, #normalize_output, #normalize_value, #result
Constructor Details
This class inherits a constructor from Reflection
Instance Method Details
#reflect(*args) ⇒ Object
Reflect on a method.
Creates a shadow execution stack.
15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 |
# File 'lib/Control.rb', line 15 def reflect(*args) @input = *args # Action method with new arguments. begin @output = @clone.send(@method, *@input) # When fail. rescue StandardError => @status = FAIL @message = # When pass. else @status = PASS end end |