Exception: Libis::Services::HttpError
- Inherits:
-
Exception
- Object
- Exception
- Libis::Services::HttpError
- Defined in:
- lib/libis/services/http_error.rb
Instance Attribute Summary collapse
-
#body ⇒ Object
Returns the value of attribute body.
-
#code ⇒ Object
Returns the value of attribute code.
-
#header ⇒ Object
Returns the value of attribute header.
Instance Method Summary collapse
-
#initialize(error) ⇒ HttpError
constructor
A new instance of HttpError.
- #message ⇒ Object
Constructor Details
#initialize(error) ⇒ HttpError
Returns a new instance of HttpError.
9 10 11 12 13 |
# File 'lib/libis/services/http_error.rb', line 9 def initialize(error) @code = error[:code] @header = error[:header] @body = error[:body] end |
Instance Attribute Details
#body ⇒ Object
Returns the value of attribute body.
7 8 9 |
# File 'lib/libis/services/http_error.rb', line 7 def body @body end |
#code ⇒ Object
Returns the value of attribute code.
7 8 9 |
# File 'lib/libis/services/http_error.rb', line 7 def code @code end |
#header ⇒ Object
Returns the value of attribute header.
7 8 9 |
# File 'lib/libis/services/http_error.rb', line 7 def header @header end |
Instance Method Details
#message ⇒ Object
15 16 17 |
# File 'lib/libis/services/http_error.rb', line 15 def code.to_s end |