|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectplay.libs.ws.ning.NingWSResponse
public class NingWSResponse
A WS response.
| Constructor Summary | |
|---|---|
NingWSResponse(com.ning.http.client.Response ahcResponse)
|
|
| Method Summary | |
|---|---|
byte[] |
asByteArray()
Get the response body as a byte array |
com.fasterxml.jackson.databind.JsonNode |
asJson()
Get the response body as a JsonNode |
org.w3c.dom.Document |
asXml()
Get the response body as a DOM document |
java.util.Map<java.lang.String,java.util.List<java.lang.String>> |
getAllHeaders()
Get all the HTTP headers of the response as a case-insensitive map |
java.lang.String |
getBody()
Get the response body as a string. |
java.io.InputStream |
getBodyAsStream()
Get the response body as a stream |
WSCookie |
getCookie(java.lang.String name)
Get only one cookie, using the cookie name. |
java.util.List<WSCookie> |
getCookies()
Get all the cookies. |
java.lang.String |
getHeader(java.lang.String key)
Get the given HTTP header of the response |
int |
getStatus()
Get the HTTP status code of the response |
java.lang.String |
getStatusText()
Get the HTTP status text of the response |
java.lang.Object |
getUnderlying()
|
java.net.URI |
getUri()
Return the request URI. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public NingWSResponse(com.ning.http.client.Response ahcResponse)
| Method Detail |
|---|
public java.lang.Object getUnderlying()
getUnderlying in interface WSResponsepublic int getStatus()
getStatus in interface WSResponsepublic java.lang.String getStatusText()
getStatusText in interface WSResponsepublic java.util.Map<java.lang.String,java.util.List<java.lang.String>> getAllHeaders()
getAllHeaders in interface WSResponsepublic java.lang.String getHeader(java.lang.String key)
getHeader in interface WSResponsepublic java.util.List<WSCookie> getCookies()
getCookies in interface WSResponsepublic WSCookie getCookie(java.lang.String name)
getCookie in interface WSResponsepublic java.lang.String getBody()
getBody in interface WSResponsepublic org.w3c.dom.Document asXml()
DOM document
asXml in interface WSResponsepublic com.fasterxml.jackson.databind.JsonNode asJson()
JsonNode
asJson in interface WSResponsepublic java.io.InputStream getBodyAsStream()
getBodyAsStream in interface WSResponsepublic byte[] asByteArray()
asByteArray in interface WSResponsepublic java.net.URI getUri()
URI. Note that if the request got redirected, the value of the
URI will be the last valid redirect url.
getUri in interface WSResponseURI.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||