public static class WSAsync.HttpAsyncResponse extends WS.HttpResponse
Constructor and Description |
---|
HttpAsyncResponse(com.ning.http.client.Response response)
You shouldn't have to create an HttpResponse yourself
|
Modifier and Type | Method and Description |
---|---|
java.lang.String |
getHeader(java.lang.String key) |
java.util.List<Http.Header> |
getHeaders() |
java.lang.Integer |
getStatus()
The HTTP status code
|
java.lang.String |
getStatusText()
the HTTP status text
|
java.io.InputStream |
getStream()
get the response as a stream
|
java.lang.String |
getString()
get the response body as a string
|
java.lang.String |
getString(java.lang.String encoding)
get the response body as a string
|
getContentType, getEncoding, getJson, getQueryString, getXml, getXml, success
public HttpAsyncResponse(com.ning.http.client.Response response)
response
- The given responsepublic java.lang.Integer getStatus()
getStatus
in class WS.HttpResponse
public java.lang.String getStatusText()
getStatusText
in class WS.HttpResponse
public java.lang.String getHeader(java.lang.String key)
getHeader
in class WS.HttpResponse
public java.util.List<Http.Header> getHeaders()
getHeaders
in class WS.HttpResponse
public java.lang.String getString()
WS.HttpResponse
getString
in class WS.HttpResponse
public java.lang.String getString(java.lang.String encoding)
WS.HttpResponse
getString
in class WS.HttpResponse
encoding
- string charset encodingpublic java.io.InputStream getStream()
getStream
in class WS.HttpResponse
Guillaume Bort & zenexity - Distributed under Apache 2 licence, without any warrantly