|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.http.message.AbstractHttpMessage
org.apache.http.message.BasicHttpResponse
public class BasicHttpResponse
Basic implementation of an HTTP response that can be modified.
Constructor Summary | |
---|---|
BasicHttpResponse()
|
|
BasicHttpResponse(StatusLine statusline)
|
Method Summary | |
---|---|
HttpEntity |
getEntity()
Returns the response entity of this response as set by |
HttpVersion |
getHttpVersion()
Returns the HTTP version this message is compatible with. |
StatusLine |
getStatusLine()
Returns the status line that belongs to this response as set by |
void |
setEntity(HttpEntity entity)
Associates a response entity with this response. |
void |
setStatusCode(int code)
Convenience method that creates and sets a new status line of this response that is initialized with the specified status code. |
void |
setStatusLine(StatusLine statusline)
Sets the status line that belongs to this response. |
Methods inherited from class org.apache.http.message.AbstractHttpMessage |
---|
addHeader, containsHeader, getAllHeaders, getFirstHeader, getHeaders, getLastHeader, getParams, headerIterator, removeHeader, removeHeaders, setHeader, setParams |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.apache.http.HttpMessage |
---|
addHeader, containsHeader, getAllHeaders, getFirstHeader, getHeaders, getLastHeader, getParams, headerIterator, removeHeader, removeHeaders, setHeader, setParams |
Constructor Detail |
---|
public BasicHttpResponse()
public BasicHttpResponse(StatusLine statusline)
Method Detail |
---|
public HttpVersion getHttpVersion()
HttpMessage
getHttpVersion
in interface HttpMessage
public StatusLine getStatusLine()
HttpResponse
getStatusLine
in interface HttpResponse
public HttpEntity getEntity()
HttpResponse
getEntity
in interface HttpResponse
null
if there is none.public void setStatusLine(StatusLine statusline)
HttpResponse
setStatusLine
in interface HttpResponse
statusline
- the status line of this response.public void setStatusCode(int code)
HttpResponse
setStatusCode
in interface HttpResponse
code
- the HTTP status code.HttpStatus
public void setEntity(HttpEntity entity)
HttpResponse
setEntity
in interface HttpResponse
entity
- the entity to associate with this response.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |