Exception: TCPClient::TimeoutError
- Inherits:
-
NetworkError
- Object
- StandardError
- NetworkError
- TCPClient::TimeoutError
- Defined in:
- lib/tcp-client/errors.rb
Overview
Base exception class for a detected timeout.
You should catch this exception class when you like to handle any timeout error.
Direct Known Subclasses
Instance Attribute Summary collapse
-
#action ⇒ Symbol
readonly
The action which timed out.
Instance Method Summary collapse
-
#initialize(message = nil) ⇒ TimeoutError
constructor
Initializes the instance with an optional message.
Constructor Details
#initialize ⇒ TimeoutError #initialize(message) ⇒ TimeoutError
Initializes the instance with an optional message.
The message will be generated from #action when not specified.
89 90 91 |
# File 'lib/tcp-client/errors.rb', line 89 def initialize( = nil) super( || "unable to #{action} in time") end |
Instance Attribute Details
#action ⇒ Symbol (readonly)
Returns the action which timed out.
97 |
# File 'lib/tcp-client/errors.rb', line 97 def action = :process |