Class: ArchivesSpace::Response
- Inherits:
-
Object
- Object
- ArchivesSpace::Response
- Defined in:
- lib/archivesspace/client/response.rb
Instance Attribute Summary collapse
-
#body ⇒ Object
readonly
Returns the value of attribute body.
-
#headers ⇒ Object
readonly
Returns the value of attribute headers.
-
#parsed ⇒ Object
readonly
Returns the value of attribute parsed.
-
#result ⇒ Object
readonly
Returns the value of attribute result.
-
#status ⇒ Object
readonly
Returns the value of attribute status.
-
#status_code ⇒ Object
readonly
Returns the value of attribute status_code.
Instance Method Summary collapse
-
#initialize(result) ⇒ Response
constructor
A new instance of Response.
Constructor Details
#initialize(result) ⇒ Response
Returns a new instance of Response.
7 8 9 10 11 12 13 14 |
# File 'lib/archivesspace/client/response.rb', line 7 def initialize(result) @result = result @parsed = result.parsed_response @body = result.body @headers = result.headers @status = result.response @status_code = result.code.to_i end |
Instance Attribute Details
#body ⇒ Object (readonly)
Returns the value of attribute body.
5 6 7 |
# File 'lib/archivesspace/client/response.rb', line 5 def body @body end |
#headers ⇒ Object (readonly)
Returns the value of attribute headers.
5 6 7 |
# File 'lib/archivesspace/client/response.rb', line 5 def headers @headers end |
#parsed ⇒ Object (readonly)
Returns the value of attribute parsed.
5 6 7 |
# File 'lib/archivesspace/client/response.rb', line 5 def parsed @parsed end |
#result ⇒ Object (readonly)
Returns the value of attribute result.
5 6 7 |
# File 'lib/archivesspace/client/response.rb', line 5 def result @result end |
#status ⇒ Object (readonly)
Returns the value of attribute status.
5 6 7 |
# File 'lib/archivesspace/client/response.rb', line 5 def status @status end |
#status_code ⇒ Object (readonly)
Returns the value of attribute status_code.
5 6 7 |
# File 'lib/archivesspace/client/response.rb', line 5 def status_code @status_code end |