Mapping Servlets and Filters
This procedure enables you to set servlets and filters mappings in your web application.
The displayed tabs and fields correspond to the following elements in web.xml:
<!ELEMENT servlet-mapping (servlet-name, url-pattern)>
<!ELEMENT servlet-name (#PCDATA)>
<!ELEMENT url-pattern (#PCDATA)>
<!ELEMENT filter-mapping (filter-name (url-pattern | servlet-name))>
<!ELEMENT filter-name (#PCDATA)>
To set servlet or filter mapping choose Mapping.
If You Want To |
Then |
Add a servlet or filter mapping |
1. Choose Servlet or Filter. 2. Enter the name of the servlet (or filter) to which you want to apply the mapping. 3. Enter URL pattern for the particular servlet or filter. 4.
Choose
Add.
The filter mapping process is identical except that you have the option to map a filter to a particular servlet class instead of URL pattern. |
Modify a servlet or filter mapping |
1. Select the mapping you want to modify from the Mappings list. 2. Edit the entered information and choose Modify. |
Remove a servlet or filter mapping |
Select the mapping you want to remove from the list and choose Remove. |