Class: Variable::Result
- Inherits:
-
Object
- Object
- Variable::Result
- Defined in:
- lib/variable.rb
Overview
Result of operation that may time out
Defined Under Namespace
Instance Attribute Summary collapse
-
#value ⇒ Object
readonly
Returns the value of attribute value.
Instance Method Summary collapse
-
#initialize(value) ⇒ undefined
constructor
Initialize result.
-
#timeout? ⇒ Boolean
private
Test if take resulted in a timeout.
Constructor Details
#initialize(value) ⇒ undefined
Initialize result
25 26 27 28 |
# File 'lib/variable.rb', line 25 def initialize(value) @value = value freeze end |
Instance Attribute Details
#value ⇒ Object (readonly)
Returns the value of attribute value.
20 21 22 |
# File 'lib/variable.rb', line 20 def value @value end |
Instance Method Details
#timeout? ⇒ Boolean
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Test if take resulted in a timeout
35 36 37 |
# File 'lib/variable.rb', line 35 def timeout? instance_of?(Timeout) end |