Class: SmoothOperator::RemoteCall::Errors::Base
- Inherits:
-
Object
- Object
- SmoothOperator::RemoteCall::Errors::Base
- Defined in:
- lib/smooth_operator/remote_call/errors/base.rb
Direct Known Subclasses
Instance Attribute Summary collapse
-
#body ⇒ Object
readonly
Returns the value of attribute body.
-
#data ⇒ Object
readonly
Returns the value of attribute data.
-
#headers ⇒ Object
readonly
Returns the value of attribute headers.
-
#object ⇒ Object
readonly
Returns the value of attribute object.
-
#objects ⇒ Object
readonly
Returns the value of attribute objects.
-
#parsed_response ⇒ Object
readonly
Returns the value of attribute parsed_response.
-
#response ⇒ Object
readonly
Returns the value of attribute response.
-
#status ⇒ Object
readonly
Returns the value of attribute status.
Instance Method Summary collapse
- #error? ⇒ Boolean
- #failure? ⇒ Boolean
- #http_status ⇒ Object
-
#initialize(response) ⇒ Base
constructor
A new instance of Base.
- #success? ⇒ Boolean (also: #ok?)
Constructor Details
#initialize(response) ⇒ Base
Returns a new instance of Base.
9 10 11 |
# File 'lib/smooth_operator/remote_call/errors/base.rb', line 9 def initialize(response) @response = response end |
Instance Attribute Details
#body ⇒ Object (readonly)
Returns the value of attribute body.
7 8 9 |
# File 'lib/smooth_operator/remote_call/errors/base.rb', line 7 def body @body end |
#data ⇒ Object (readonly)
Returns the value of attribute data.
7 8 9 |
# File 'lib/smooth_operator/remote_call/errors/base.rb', line 7 def data @data end |
#headers ⇒ Object (readonly)
Returns the value of attribute headers.
7 8 9 |
# File 'lib/smooth_operator/remote_call/errors/base.rb', line 7 def headers @headers end |
#object ⇒ Object (readonly)
Returns the value of attribute object.
7 8 9 |
# File 'lib/smooth_operator/remote_call/errors/base.rb', line 7 def object @object end |
#objects ⇒ Object (readonly)
Returns the value of attribute objects.
7 8 9 |
# File 'lib/smooth_operator/remote_call/errors/base.rb', line 7 def objects @objects end |
#parsed_response ⇒ Object (readonly)
Returns the value of attribute parsed_response.
7 8 9 |
# File 'lib/smooth_operator/remote_call/errors/base.rb', line 7 def parsed_response @parsed_response end |
#response ⇒ Object (readonly)
Returns the value of attribute response.
7 8 9 |
# File 'lib/smooth_operator/remote_call/errors/base.rb', line 7 def response @response end |
#status ⇒ Object (readonly)
Returns the value of attribute status.
7 8 9 |
# File 'lib/smooth_operator/remote_call/errors/base.rb', line 7 def status @status end |
Instance Method Details
#error? ⇒ Boolean
15 |
# File 'lib/smooth_operator/remote_call/errors/base.rb', line 15 def error?; true; end |
#failure? ⇒ Boolean
19 |
# File 'lib/smooth_operator/remote_call/errors/base.rb', line 19 def failure?; false; end |
#http_status ⇒ Object
13 |
# File 'lib/smooth_operator/remote_call/errors/base.rb', line 13 def http_status; 0; end |
#success? ⇒ Boolean Also known as: ok?
17 |
# File 'lib/smooth_operator/remote_call/errors/base.rb', line 17 def success?; false; end |