Name
HttpServletResponseWrapper
Synopsis
A convenience class that can be used by filter developers to modify
the behavior of a HttpServletResponse
object. The default
implementation of each method calls through to the original
HttpServletResponse
object, and methods can be selectively
overridden to provide additional functionality.
HttpServletResponseWrapper
objects can also be used in
calls to the forward()
and
include()
methods of RequestDispatcher
.
public class HttpServletResponseWrapper extends ServletResponseWrapper implements HttpServletResponse { // Public Constructors public HttpServletResponseWrapper( HttpServletResponse response); // Methods Implementing HttpServletResponse public void addCookie( Cookie cookie); public void addDateHeader( String name, long date); public void addHeader( String name, String value); public void addIntHeader( String name, int value); public boolean containsHeader( String name); public String encodeRedirectUrl( String url); public String encodeRedirectURL( String url); public String encodeURL( String url); public String encodeUrl( String url); public void sendError( int sc) throws IOException; public void sendError(int sc, String msg) throws IOException; public void sendRedirect( String location) throws IOException; public void setDateHeader( String name, long date); public void setHeader( String name, String value); public void setIntHeader ...
Get Java Enterprise in a Nutshell, Second Edition now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.