public class AhcWSResponse extends java.lang.Object implements WSResponse
Constructor and Description |
---|
AhcWSResponse(StandaloneWSResponse response) |
Modifier and Type | Method and Description |
---|---|
byte[] |
asByteArray() |
com.fasterxml.jackson.databind.JsonNode |
asJson() |
org.w3c.dom.Document |
asXml() |
java.util.Map<java.lang.String,java.util.List<java.lang.String>> |
getAllHeaders() |
java.lang.String |
getBody() |
java.io.InputStream |
getBodyAsStream() |
WSCookie |
getCookie(java.lang.String name) |
java.util.List<WSCookie> |
getCookies() |
java.lang.String |
getHeader(java.lang.String key) |
int |
getStatus() |
java.lang.String |
getStatusText() |
java.lang.Object |
getUnderlying() |
java.net.URI |
getUri() |
public AhcWSResponse(StandaloneWSResponse response)
public java.util.Map<java.lang.String,java.util.List<java.lang.String>> getAllHeaders()
getAllHeaders
in interface StandaloneWSResponse
public java.lang.String getHeader(java.lang.String key)
getHeader
in interface StandaloneWSResponse
key
- the header's namepublic java.lang.Object getUnderlying()
getUnderlying
in interface StandaloneWSResponse
public int getStatus()
getStatus
in interface StandaloneWSResponse
public java.lang.String getStatusText()
getStatusText
in interface StandaloneWSResponse
public java.util.List<WSCookie> getCookies()
getCookies
in interface StandaloneWSResponse
public WSCookie getCookie(java.lang.String name)
getCookie
in interface StandaloneWSResponse
name
- the cookie namepublic java.lang.String getBody()
getBody
in interface StandaloneWSResponse
public org.w3c.dom.Document asXml()
asXml
in interface StandaloneWSResponse
public com.fasterxml.jackson.databind.JsonNode asJson()
asJson
in interface StandaloneWSResponse
public java.io.InputStream getBodyAsStream()
getBodyAsStream
in interface StandaloneWSResponse
public byte[] asByteArray()
asByteArray
in interface StandaloneWSResponse
public java.net.URI getUri()
getUri
in interface StandaloneWSResponse