Exception: VectorAmp::APIError
- Defined in:
- lib/vector_amp/error.rb
Instance Attribute Summary collapse
-
#body ⇒ Object
readonly
Returns the value of attribute body.
-
#headers ⇒ Object
readonly
Returns the value of attribute headers.
-
#status ⇒ Object
readonly
Returns the value of attribute status.
Instance Method Summary collapse
-
#initialize(message, status: nil, body: nil, headers: {}) ⇒ APIError
constructor
A new instance of APIError.
Constructor Details
#initialize(message, status: nil, body: nil, headers: {}) ⇒ APIError
Returns a new instance of APIError.
10 11 12 13 14 15 |
# File 'lib/vector_amp/error.rb', line 10 def initialize(, status: nil, body: nil, headers: {}) super() @status = status @body = body @headers = headers end |
Instance Attribute Details
#body ⇒ Object (readonly)
Returns the value of attribute body.
8 9 10 |
# File 'lib/vector_amp/error.rb', line 8 def body @body end |
#headers ⇒ Object (readonly)
Returns the value of attribute headers.
8 9 10 |
# File 'lib/vector_amp/error.rb', line 8 def headers @headers end |
#status ⇒ Object (readonly)
Returns the value of attribute status.
8 9 10 |
# File 'lib/vector_amp/error.rb', line 8 def status @status end |