Hi

I am writing a filter and want to be able to set the values of
Cache-Control, Pragma, Expires in the response.  However I cannot
do this, here is an outline of what I have

------------snip start------------------
public class TestFilter implements Filter
{
    private FilterConfig filterConfig;
    public void doFilter (ServletRequest request,
                          ServletResponse response,
                          FilterChain chain)
    {
        try
        {
             ///I want to do the following lines, but
            //ServletResponse does not have a setHeader() method
            response.setHeader("Cache-Control", "no-cache");
            response.setHeader("Pragma", "no-cache");
            response.setHeader("Expires", "-1");

------------snip end------------------

How can I set these values?

Cheers

Tony

_________________________________________________________
Do You Yahoo!?
Get your free @yahoo.com address at http://mail.yahoo.com


___________________________________________________________________________
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff SERVLET-INTEREST".

Archives: http://archives.java.sun.com/archives/servlet-interest.html
Resources: http://java.sun.com/products/servlet/external-resources.html
LISTSERV Help: http://www.lsoft.com/manuals/user/user.html

Reply via email to