|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Encapsulates a HTTP response.
Field Summary | |
static int |
SC_FORBIDDEN
Status code indicating that the server understood the request but refused to fulfill it. |
static int |
SC_INTERNAL_SERVER_ERROR
Status code indicating that an error occured inside the server. |
static int |
SC_MOVED_PERMANENTLY
Moved Permanently |
static int |
SC_NOT_FOUND
Status code indicating that the request resource is not available. |
static int |
SC_OK
Status code indicating that request succeeded normally. |
Method Summary | |
ByteSource |
getBody()
Gets the source to read the body from. |
int |
getStatus()
Gets the response status. |
void |
setBody(ByteSource to)
Sets the source to read the body from. |
void |
setHeader(java.lang.String name,
java.lang.String value)
Sets a header. |
void |
setStatus(int to)
Sets the response status. |
Methods inherited from interface juju.reattore.protocol.http.HttpMessage |
getHeader, getHeaders, getNumHeaders |
Field Detail |
public static final int SC_OK
public static final int SC_NOT_FOUND
public static final int SC_INTERNAL_SERVER_ERROR
public static final int SC_FORBIDDEN
public static final int SC_MOVED_PERMANENTLY
Method Detail |
public void setStatus(int to)
to
- One of the SC_* constants.public void setBody(ByteSource to)
to
- The source.public void setHeader(java.lang.String name, java.lang.String value)
name
- One of HttpConstants.*value
- The value to use.public int getStatus()
public ByteSource getBody()
getBody
in interface HttpMessage
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |