public class RemoteConnectorResponseImpl extends Object implements RemoteConnectorResponse
RemoteConnectorService.| Constructor and Description |
|---|
RemoteConnectorResponseImpl(RemoteConnectorRequest request,
String contentType,
String charset,
int status,
org.apache.commons.httpclient.Header[] headers,
byte[] response) |
RemoteConnectorResponseImpl(RemoteConnectorRequest request,
String contentType,
String charset,
int status,
org.apache.commons.httpclient.Header[] headers,
InputStream response)
Creates a new Response object with the data coming from a stream.
|
| Modifier and Type | Method and Description |
|---|---|
String |
getCharset() |
String |
getContentType() |
String |
getRawContentType() |
RemoteConnectorRequest |
getRequest() |
byte[] |
getResponseBodyAsBytes() |
InputStream |
getResponseBodyAsStream() |
String |
getResponseBodyAsString() |
org.apache.commons.httpclient.Header[] |
getResponseHeaders() |
int |
getStatus() |
public RemoteConnectorResponseImpl(RemoteConnectorRequest request, String contentType, String charset, int status, org.apache.commons.httpclient.Header[] headers, InputStream response)
public RemoteConnectorResponseImpl(RemoteConnectorRequest request, String contentType, String charset, int status, org.apache.commons.httpclient.Header[] headers, byte[] response)
public int getStatus()
getStatus in interface RemoteConnectorResponseStatus Code for the responsepublic String getCharset()
getCharset in interface RemoteConnectorResponsepublic String getContentType()
getContentType in interface RemoteConnectorResponsepublic String getRawContentType()
getRawContentType in interface RemoteConnectorResponsepublic RemoteConnectorRequest getRequest()
getRequest in interface RemoteConnectorResponsepublic org.apache.commons.httpclient.Header[] getResponseHeaders()
getResponseHeaders in interface RemoteConnectorResponsepublic byte[] getResponseBodyAsBytes()
throws IOException
getResponseBodyAsBytes in interface RemoteConnectorResponseIOExceptionpublic InputStream getResponseBodyAsStream()
getResponseBodyAsStream in interface RemoteConnectorResponsepublic String getResponseBodyAsString() throws IOException
getResponseBodyAsString in interface RemoteConnectorResponseIOExceptionCopyright © 2005–2018 Alfresco Software. All rights reserved.