class ResponseHeaderFilter implements Filter {
    FilterConfig fc;

    @Override
    public void doFilter(ServletRequest req, ServletResponse res,
        FilterChain chain)
        throws IOException, ServletException {<FILL_FUNCTION_BODY>}

    @Override
    public void init(FilterConfig filterConfig) {
        this.fc = filterConfig;
    }

    @Override
    public void destroy() {
        this.fc = null;
    }
}


        HttpServletResponse response = (HttpServletResponse) res;

        // set the provided HTTP response parameters
        for (Enumeration<String> e = fc.getInitParameterNames(); e.hasMoreElements();) {
            String headerName = e.nextElement();
            if (!response.containsHeader(headerName)) {
                response.addHeader(headerName, fc.getInitParameter(headerName));
            }
        }

        // pass the request/response on
        chain.doFilter(req, response);
    
<no_super_class>