Represents an HTTP response
| Constructor and description |
|---|
HttpClientResponse
(io.netty.handler.codec.http.FullHttpResponse response) |
HttpClientResponse
(io.netty.handler.codec.http.FullHttpResponse response, java.lang.String encoding) |
HttpClientResponse
(io.netty.handler.codec.http.FullHttpResponse response, java.nio.charset.Charset charset) |
| Type | Name and description |
|---|---|
java.lang.String |
getHeader(java.lang.String name)Obtain a value of a header |
java.io.InputStream |
getInputStream()Obtain an input stream from the body |
java.lang.Object |
getJson()@return The JSON representation of the response body |
HttpStatus |
getStatus()@return The returned http status object |
int |
getStatusCode()@return The status code of the response |
java.lang.String |
getStatusReason()@return The reason message |
java.lang.String |
getText()@return The textual content of the body |
java.lang.String |
getText(java.nio.charset.Charset charset)@return The textual content of the body |
groovy.util.slurpersupport.GPathResult |
getXml()@return An XML representation for the response body |
java.lang.String |
header(java.lang.String name)Obtain a value of a header |
java.lang.String |
toString() |
| Methods inherited from class | Name |
|---|---|
class java.lang.Object |
java.lang.Object#wait(long, int), java.lang.Object#wait(long), java.lang.Object#wait(), java.lang.Object#equals(java.lang.Object), java.lang.Object#toString(), java.lang.Object#hashCode(), java.lang.Object#getClass(), java.lang.Object#notify(), java.lang.Object#notifyAll() |
Obtain a value of a header
name - The header nameObtain an input stream from the body
Obtain a value of a header
name - The header nameGroovy Documentation