Exception: Pipe2me::HTTP::Error
- Inherits:
-
RuntimeError
- Object
- RuntimeError
- Pipe2me::HTTP::Error
- Extended by:
- Forwardable
- Defined in:
- lib/pipe2me/ext/http.rb
Overview
Base class for HTTP related errors.
Direct Known Subclasses
Instance Attribute Summary collapse
-
#response ⇒ Object
readonly
The response object (of class HTTP::Response).
Instance Method Summary collapse
-
#initialize(response) ⇒ Error
constructor
:nodoc:.
-
#message ⇒ Object
:nodoc:.
Constructor Details
#initialize(response) ⇒ Error
:nodoc:
29 30 31 |
# File 'lib/pipe2me/ext/http.rb', line 29 def initialize(response) #:nodoc: @response = response end |
Instance Attribute Details
#response ⇒ Object (readonly)
The response object (of class HTTP::Response).
27 28 29 |
# File 'lib/pipe2me/ext/http.rb', line 27 def response @response end |
Instance Method Details
#message ⇒ Object
:nodoc:
36 37 38 |
# File 'lib/pipe2me/ext/http.rb', line 36 def #:nodoc: "#{url}: #{code} #{@response[0..120]} (#{@response.response.class})" end |