Class: Mutant::Variable::Result Private

Inherits:
Object
  • Object
show all
Defined in:
lib/mutant/variable.rb

Overview

This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.

Result of operation that may time out

Direct Known Subclasses

Timeout, Value

Defined Under Namespace

Classes: Timeout, Value

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(value) ⇒ undefined

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.

Initialize result



25
26
27
28
# File 'lib/mutant/variable.rb', line 25

def initialize(value)
  @value = value
  freeze
end

Instance Attribute Details

#valueObject (readonly)

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.



20
21
22
# File 'lib/mutant/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

Returns:

  • (Boolean)


35
36
37
# File 'lib/mutant/variable.rb', line 35

def timeout?
  instance_of?(Timeout)
end