<?xml version = "1.0" encoding = "ISO-8859-1"?> <!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN" "http://java.sun.com/j2ee/dtds/web-app_2_3.dtd";>
<web-app> <!-- Define the filters within the Web Application --> <filter> <filter-name> Simple Filter Example </filter-name> <filter-class> com.filters.SimpleFilter </filter-class> </filter> <!-- Map the filter to a Servlet or URL --> <filter-mapping> <filter-name> Simple Filter Example </filter-name> <url-pattern> /simple </url-pattern> </filter-mapping> <!-- Define the Servlets within the Web Application --> <servlet> <servlet-name> Simple Servlet </servlet-name> <servlet-class> com.servlets.SimpleServlet </servlet-class> </servlet> <!-- Define Servlet mappings to urls --> <servlet-mapping> <servlet-name> Simple Servlet </servlet-name> <url-pattern> /simple </url-pattern> </servlet-mapping> </web-app>