
public class ServletHttpResponse extends AbstractHttpResponse implements HttpResponse
SC_INTERNAL_SERVER_ERROR, SC_NOT_FOUND, SC_OK| Modifier and Type | Method and Description |
|---|---|
static ServletHttpResponse |
fromHttpServletResponse(javax.servlet.http.HttpServletResponse httpServletResponse) |
OutputStream |
getBodyOutputStream() |
Writer |
getBodyWriter() |
javax.servlet.http.HttpServletResponse |
getHttpServletResponse() |
void |
sendError(int sc,
String msg) |
void |
sendRedirect(String location) |
void |
setContentLength(int len) |
void |
setContentType(String type) |
void |
setHeader(String name,
String value) |
void |
setStatus(int sc) |
public static ServletHttpResponse fromHttpServletResponse(javax.servlet.http.HttpServletResponse httpServletResponse)
public javax.servlet.http.HttpServletResponse getHttpServletResponse()
public void setStatus(int sc)
setStatus in interface HttpResponsepublic void setContentType(String type)
setContentType in interface HttpResponsepublic void setContentLength(int len)
setContentLength in interface HttpResponsepublic void setHeader(String name, String value)
setHeader in interface HttpResponsepublic void sendRedirect(String location) throws IOException
sendRedirect in interface HttpResponseIOExceptionpublic void sendError(int sc,
String msg)
throws IOException
sendError in interface HttpResponseIOExceptionpublic Writer getBodyWriter() throws IOException
getBodyWriter in interface HttpResponseIOExceptionpublic OutputStream getBodyOutputStream() throws IOException
getBodyOutputStream in interface HttpResponseIOExceptionCopyright © 2015. All Rights Reserved.