Exception: MediawikiApi::HttpError
- Inherits:
-
StandardError
- Object
- StandardError
- MediawikiApi::HttpError
- Defined in:
- lib/mediawiki_api/exceptions.rb
Overview
for errors from HTTP requests
Instance Attribute Summary collapse
-
#status ⇒ Object
readonly
Returns the value of attribute status.
Instance Method Summary collapse
-
#initialize(status) ⇒ HttpError
constructor
A new instance of HttpError.
- #to_s ⇒ Object
Constructor Details
#initialize(status) ⇒ HttpError
Returns a new instance of HttpError.
40 41 42 |
# File 'lib/mediawiki_api/exceptions.rb', line 40 def initialize(status) @status = status end |
Instance Attribute Details
#status ⇒ Object (readonly)
Returns the value of attribute status.
38 39 40 |
# File 'lib/mediawiki_api/exceptions.rb', line 38 def status @status end |
Instance Method Details
#to_s ⇒ Object
44 45 46 |
# File 'lib/mediawiki_api/exceptions.rb', line 44 def to_s "unexpected HTTP response (#{status})" end |