@NotThreadSafe public class HttpResponseProxy extends Object implements org.apache.http.client.methods.CloseableHttpResponse
HttpResponse
.Constructor and Description |
---|
HttpResponseProxy(org.apache.http.HttpResponse original) |
Modifier and Type | Method and Description |
---|---|
void |
addHeader(org.apache.http.Header header) |
void |
addHeader(String name,
String value) |
void |
close() |
boolean |
containsHeader(String name) |
org.apache.http.Header[] |
getAllHeaders() |
org.apache.http.HttpEntity |
getEntity() |
org.apache.http.Header |
getFirstHeader(String name) |
org.apache.http.Header[] |
getHeaders(String name) |
org.apache.http.Header |
getLastHeader(String name) |
Locale |
getLocale() |
org.apache.http.params.HttpParams |
getParams()
Deprecated.
|
org.apache.http.ProtocolVersion |
getProtocolVersion() |
org.apache.http.StatusLine |
getStatusLine() |
org.apache.http.HeaderIterator |
headerIterator() |
org.apache.http.HeaderIterator |
headerIterator(String name) |
void |
removeHeader(org.apache.http.Header header) |
void |
removeHeaders(String name) |
void |
setEntity(org.apache.http.HttpEntity entity) |
void |
setHeader(org.apache.http.Header header) |
void |
setHeader(String name,
String value) |
void |
setHeaders(org.apache.http.Header[] headers) |
void |
setLocale(Locale loc) |
void |
setParams(org.apache.http.params.HttpParams params)
Deprecated.
|
void |
setReasonPhrase(String reason) |
void |
setStatusCode(int code) |
void |
setStatusLine(org.apache.http.ProtocolVersion ver,
int code) |
void |
setStatusLine(org.apache.http.ProtocolVersion ver,
int code,
String reason) |
void |
setStatusLine(org.apache.http.StatusLine statusline) |
String |
toString() |
public HttpResponseProxy(org.apache.http.HttpResponse original)
public void close() throws IOException
close
in interface Closeable
close
in interface AutoCloseable
IOException
public org.apache.http.StatusLine getStatusLine()
getStatusLine
in interface org.apache.http.HttpResponse
public void setStatusLine(org.apache.http.StatusLine statusline)
setStatusLine
in interface org.apache.http.HttpResponse
public void setStatusLine(org.apache.http.ProtocolVersion ver, int code)
setStatusLine
in interface org.apache.http.HttpResponse
public void setStatusLine(org.apache.http.ProtocolVersion ver, int code, String reason)
setStatusLine
in interface org.apache.http.HttpResponse
public void setStatusCode(int code) throws IllegalStateException
setStatusCode
in interface org.apache.http.HttpResponse
IllegalStateException
public void setReasonPhrase(String reason) throws IllegalStateException
setReasonPhrase
in interface org.apache.http.HttpResponse
IllegalStateException
public org.apache.http.HttpEntity getEntity()
getEntity
in interface org.apache.http.HttpResponse
public void setEntity(org.apache.http.HttpEntity entity)
setEntity
in interface org.apache.http.HttpResponse
public Locale getLocale()
getLocale
in interface org.apache.http.HttpResponse
public void setLocale(Locale loc)
setLocale
in interface org.apache.http.HttpResponse
public org.apache.http.ProtocolVersion getProtocolVersion()
getProtocolVersion
in interface org.apache.http.HttpMessage
public boolean containsHeader(String name)
containsHeader
in interface org.apache.http.HttpMessage
public org.apache.http.Header[] getHeaders(String name)
getHeaders
in interface org.apache.http.HttpMessage
public org.apache.http.Header getFirstHeader(String name)
getFirstHeader
in interface org.apache.http.HttpMessage
public org.apache.http.Header getLastHeader(String name)
getLastHeader
in interface org.apache.http.HttpMessage
public org.apache.http.Header[] getAllHeaders()
getAllHeaders
in interface org.apache.http.HttpMessage
public void addHeader(org.apache.http.Header header)
addHeader
in interface org.apache.http.HttpMessage
public void addHeader(String name, String value)
addHeader
in interface org.apache.http.HttpMessage
public void setHeader(org.apache.http.Header header)
setHeader
in interface org.apache.http.HttpMessage
public void setHeader(String name, String value)
setHeader
in interface org.apache.http.HttpMessage
public void setHeaders(org.apache.http.Header[] headers)
setHeaders
in interface org.apache.http.HttpMessage
public void removeHeader(org.apache.http.Header header)
removeHeader
in interface org.apache.http.HttpMessage
public void removeHeaders(String name)
removeHeaders
in interface org.apache.http.HttpMessage
public org.apache.http.HeaderIterator headerIterator()
headerIterator
in interface org.apache.http.HttpMessage
public org.apache.http.HeaderIterator headerIterator(String name)
headerIterator
in interface org.apache.http.HttpMessage
@Deprecated public org.apache.http.params.HttpParams getParams()
getParams
in interface org.apache.http.HttpMessage
@Deprecated public void setParams(org.apache.http.params.HttpParams params)
setParams
in interface org.apache.http.HttpMessage
Copyright © 2020. All rights reserved.