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 RemoteConnectorResponse
Status
Code for the responsepublic String getCharset()
getCharset
in interface RemoteConnectorResponse
public String getContentType()
getContentType
in interface RemoteConnectorResponse
public String getRawContentType()
getRawContentType
in interface RemoteConnectorResponse
public RemoteConnectorRequest getRequest()
getRequest
in interface RemoteConnectorResponse
public org.apache.commons.httpclient.Header[] getResponseHeaders()
getResponseHeaders
in interface RemoteConnectorResponse
public byte[] getResponseBodyAsBytes() throws IOException
getResponseBodyAsBytes
in interface RemoteConnectorResponse
IOException
public InputStream getResponseBodyAsStream()
getResponseBodyAsStream
in interface RemoteConnectorResponse
public String getResponseBodyAsString() throws IOException
getResponseBodyAsString
in interface RemoteConnectorResponse
IOException
Copyright © 2005–2017 Alfresco Software. All rights reserved.