Exception: AsyncAware::ThreadTimedOut

Inherits:
StandardError
  • Object
show all
Defined in:
app/models/async_aware.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(thread, timeout) ⇒ ThreadTimedOut

Returns a new instance of ThreadTimedOut.



53
54
55
# File 'app/models/async_aware.rb', line 53

def initialize(thread, timeout)
  @thread, @timeout = thread, timeout
end

Instance Attribute Details

#threadObject (readonly)

Returns the value of attribute thread.



52
53
54
# File 'app/models/async_aware.rb', line 52

def thread
  @thread
end

Instance Method Details

#to_sObject



56
57
58
# File 'app/models/async_aware.rb', line 56

def to_s
  "The thread #{thread.inspect} did not complete within #{@timeout} seconds."
end