Method Summary |
|
public void | addCookie(Cookie cookie) Add a cookie to this response, which will then be stored in the browser. |
public void | addDateHeader(String name, long date) This method is not supported. |
public void | addHeader(String name, String value) Adds a response header with the given name and value. |
public void | addIntHeader(String name, int value) Adds a response header with the given name and integer value. |
public boolean | containsHeader(String name) |
public String | encodeRedirectURL(String url) Returns the given URL unmodified. |
public String | encodeRedirectUrl(String url) |
public String | encodeURL(String url) |
public String | encodeUrl(String url) Returns the given URL unmodified. |
public Cookie | findCookie(String name) Returns a cookie with a given, or null if this cookie has
not been added to the repsonse. |
public void | flushBuffer() This method is not supported. |
public int | getBufferSize() This method is not supported. |
public String | getCharacterEncoding() This method is not supported. |
public int | getContentLength() |
public String | getContentType() |
public String | getHeader(String name) Returns a given header field, or null if this header
has not been set. |
public Locale | getLocale() Returns the locale assigned to the response. |
public String | getMessage() |
public ServletOutputStream | getOutputStream() Returns a
ServletOutputStream suitable for writing binary
data in the response. |
public int | getStatusCode() Returns the status code for this response, which is useful for testing expected errors. |
public PrintWriter | getWriter() Returns a PrintWriter object that
can send character text to the client. |
public StringBuffer | getWriterBuffer() Use this method to pick up the string buffer which will hold
the contents of the string buffer. |
public boolean | isCommitted() |
public void | removeHeader(String name) |
public void | reset() Reinitializes all local variables. |
public void | resetBuffer() This method is not supported. |
public void | sendError(int sc) Sends an error response to the client using the specified
status clearing the buffer. |
public void | sendError(int sc, String msg) Sends an error response to the client using the specified
status clearing the buffer. |
public void | sendRedirect(String location) Resets the response and sets the appropriate redirect headers. |
public void | setBufferSize(int size) This method is not supported. |
public void | setCharacterEncoding(String charEncoding) |
public void | setContentLength(int len) Sets the length of the content body in the response
In HTTP servlets, this method sets the HTTP Content-Length header. |
public void | setContentType(String type) Sets the content type of the response being sent to
the client. |
public void | setDateHeader(String name, long date) This method is not supported. |
public void | setHeader(String name, String value) |
public void | setIntHeader(String name, int value) Adds the given name/value pair to the headers collection. |
public void | setIsCommitted(boolean isCommitted) |
public void | setLocale(Locale loc) Sets the locale of the response, setting the headers (including the
Content-Type's charset) as appropriate. |
public void | setOutputStream(OutputStream out) The default action of calling the getOutputStream method
is to return a javax.servlet.ServletOutputStream object
that sends the data to System.out . |
public void | setStatus(int sc) Sets the given status code. |
public void | setStatus(int sc, String sm) Sets the given status and an associated message. |