public class RestApiResponse extends AbstractCouchbaseResponse
RestApiRequest
. The response contains the HTTP status (code and
message), the headers as well as the body, as a String.Constructor and Description |
---|
RestApiResponse(RestApiRequest request,
HttpResponseStatus status,
HttpHeaders headers,
String body)
Create a new
RestApiResponse . |
Modifier and Type | Method and Description |
---|---|
String |
body() |
HttpHeaders |
headers() |
HttpResponseStatus |
httpStatus() |
RestApiRequest |
request()
Stub method implementation which needs to be overridden by all responses that support cloning.
|
creationTime, status, statusDetails, statusDetails, toString
public RestApiResponse(RestApiRequest request, HttpResponseStatus status, HttpHeaders headers, String body)
RestApiResponse
.request
- the original request.status
- the response status (code and message).body
- the response body, as a string.headers
- the response headers.public RestApiRequest request()
AbstractCouchbaseResponse
request
in interface CouchbaseResponse
request
in class AbstractCouchbaseResponse
public HttpResponseStatus httpStatus()
public HttpHeaders headers()
public String body()
Copyright © 2021 Couchbase, Inc.. All rights reserved.