Exception: MLB::HTTPError
- Defined in:
- lib/mlb/errors/http_error.rb
Direct Known Subclasses
Instance Attribute Summary collapse
-
#code ⇒ Object
readonly
Returns the value of attribute code.
-
#response ⇒ Object
readonly
Returns the value of attribute response.
Instance Method Summary collapse
-
#initialize(response:) ⇒ HTTPError
constructor
A new instance of HTTPError.
Constructor Details
#initialize(response:) ⇒ HTTPError
Returns a new instance of HTTPError.
8 9 10 11 12 |
# File 'lib/mlb/errors/http_error.rb', line 8 def initialize(response:) super(response.) @response = response @code = response.code end |
Instance Attribute Details
#code ⇒ Object (readonly)
Returns the value of attribute code.
6 7 8 |
# File 'lib/mlb/errors/http_error.rb', line 6 def code @code end |
#response ⇒ Object (readonly)
Returns the value of attribute response.
6 7 8 |
# File 'lib/mlb/errors/http_error.rb', line 6 def response @response end |