| Modifier and Type | Class and Description |
|---|---|
| private class | |
| private static class | |
| private class |
| Modifier and Type | Field and Description |
|---|---|
| protected Response | response
The wrapped response. |
| protected static final StringManager | sm
The string manager for this package. |
| Access | Constructor and Description |
|---|---|
| public | ResponseFacade(Response
The response to be wrapped response)Construct a wrapper for the specified response. |
| Modifier and Type | Method and Description |
|---|---|
| public void | addCookie(Cookie
the Cookie to return to the client cookie)Implements jakarta. Adds the specified cookie to the response. |
| public void | addDateHeader(String
the name of the header to set name, long the additional date value date)Implements jakarta. Adds a response header with the given name and date-value. |
| public void | addHeader(String
the name of the header name, String the additional header value If it contains octet string, it should be encoded according to RFC 2047
(http://www.ietf.org/rfc/rfc2047.txt) value)Implements jakarta. Adds a response header with the given name and value. |
| public void | addIntHeader(String
the name of the header name, int the assigned integer value value)Implements jakarta. Adds a response header with the given name and integer value. |
| private void | |
| private void | |
| public void | |
| protected Object | |
| public boolean | containsHeader(String
the header name name)Implements jakarta. Returns a boolean indicating whether the named response header has already been set. |
| public String | encodeRedirectURL(String
the url to be encoded. url)Implements jakarta. Encodes the specified URL for use in the |
| public String | encodeURL(String
the url to be encoded. url)Implements jakarta. Encodes the specified URL by including the session ID in it, or, if encoding is not needed, returns the URL unchanged. |
| public void | |
| public void | flushBuffer()
Implements jakarta. Forces any content in the buffer to be written to the client. |
| public int | getBufferSize()
Implements jakarta. Returns the actual buffer size used for the response. |
| public String | getCharacterEncoding()
Implements jakarta. Returns the name of the character encoding (MIME charset) used for the body sent in this response. |
| public String | getContentType()
Implements jakarta. Returns the content type used for the MIME body sent in this response. |
| public long | |
| public String | getHeader(String
Header name to look up name)Implements jakarta. Return the value for the specified header, or |
| public Collection | getHeaderNames()
Implements jakarta. Get the header names set for this HTTP response. |
| public Collection | getHeaders(String
Header name to look up name)Implements jakarta. Return a Collection of all the header values associated with the specified header name. |
| public Locale | getLocale()
Implements jakarta. Returns the locale specified for this response using the |
| public ServletOutputStream | getOutputStream()
Implements jakarta. Returns a |
| public int | getStatus()
Implements jakarta. Get the HTTP status code for this Response. |
| public Supplier | getTrailerFields()
Overrides default jakarta. Obtain the supplier of the trailer headers. |
| public PrintWriter | getWriter()
Implements jakarta. Returns a |
| public boolean | isCommitted()
Implements jakarta. Returns a boolean indicating if the response has been committed. |
| public boolean | |
| public void | reset()
Implements jakarta. Clears any data that exists in the buffer as well as the status code and headers. |
| public void | resetBuffer()
Implements jakarta. Clears the content of the underlying buffer in the response without clearing headers or status code. |
| public void | sendError(int
the error status code sc, String the descriptive message msg)Implements jakarta. Sends an error response to the client using the specified status code and clears the output buffer. |
| public void | sendError(int
the error status code sc)Implements jakarta. Sends an error response to the client using the specified status code and clears the buffer. |
| public void | sendRedirect(String
the redirect location URL (may be absolute or relative) location)Implements jakarta. Sends a redirect response to the client using the specified redirect location URL with the status code
|
| public void | setBufferSize(int
the preferred buffer size size)Implements jakarta. Sets the preferred buffer size for the body of the response. |
| public void | setCharacterEncoding(String
a String specifying only the character set defined by IANA Character Sets
(http://www.iana.org/assignments/character-sets) encoding)Implements jakarta. Sets the character encoding (MIME charset) of the response being sent to the client, for example, to UTF-8. |
| public void | setContentLength(int
an integer specifying the length of the content being returned to the client; sets the Content-Length
header len)Implements jakarta. Sets the length of the content body in the response In HTTP servlets, this method sets the HTTP Content-Length header. |
| public void | setContentLengthLong(long
an integer specifying the length of the content being returned to the client; sets the
Content-Length header length)Implements jakarta. 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
a type)String specifying the MIME type of the contentImplements jakarta. Sets the content type of the response being sent to the client, if the response has not been committed yet. |
| public void | setDateHeader(String
the name of the header to set name, long the assigned date value date)Implements jakarta. Sets a response header with the given name and date-value. |
| public void | setHeader(String
the name of the header name, String the header value If it contains octet string, it should be encoded according to RFC 2047
(http://www.ietf.org/rfc/rfc2047.txt) value)Implements jakarta. Sets a response header with the given name and value. |
| public void | setIntHeader(String
the name of the header name, int the assigned integer value value)Implements jakarta. Sets a response header with the given name and integer value. |
| public void | setLocale(Locale
the locale of the response loc)Implements jakarta. Sets the locale of the response, if the response has not been committed yet. |
| public void | setStatus(int
the status code sc)Implements jakarta. Sets the status code for this response. |
| public void | setTrailerFields(Supplier<Map<String, String>>
The supplier for the trailer headers supplier)Overrides default jakarta. Configure the supplier of the trailer headers. |