Exception: SourceMonitor::Fetching::HTTPError
- Inherits:
-
FetchError
- Object
- StandardError
- FetchError
- SourceMonitor::Fetching::HTTPError
- Defined in:
- lib/source_monitor/fetching/fetch_error.rb
Constant Summary collapse
- CODE =
"http_error"
Instance Attribute Summary collapse
-
#status ⇒ Object
readonly
Returns the value of attribute status.
Attributes inherited from FetchError
Instance Method Summary collapse
-
#initialize(status:, message: nil, response: nil, original_error: nil) ⇒ HTTPError
constructor
A new instance of HTTPError.
Methods inherited from FetchError
Constructor Details
#initialize(status:, message: nil, response: nil, original_error: nil) ⇒ HTTPError
Returns a new instance of HTTPError.
56 57 58 59 |
# File 'lib/source_monitor/fetching/fetch_error.rb', line 56 def initialize(status:, message: nil, response: nil, original_error: nil) @status = status super( || "HTTP #{status}", response: response, original_error: original_error) end |
Instance Attribute Details
#status ⇒ Object (readonly)
Returns the value of attribute status.
54 55 56 |
# File 'lib/source_monitor/fetching/fetch_error.rb', line 54 def status @status end |