Enabling Faces technology in an existing Web application
The JSF facets supply a set of behaviors and capabilities to your Web application. In order to use the JSF tools the JSF facets and any other facet dependencies must be added to your project.
To add a JSF facet to an existing Web application:
- In the Enterprise Explorer view, right-click your Web project and select
Properties.
- In the Properties list, click
Project Facets.
- Select the JSF facets that you want to add to your project, then click OK. If the facet you select is dependent on other project facets you will be prompted to select the required facets. For more information on the various JSF Facets, refer to JSF Facets.
When a JSF facet is added to a Web application, the following occurs:
- The JSF library JARs and other project resources (for example CSS files and images) are copied into the project.
- The project's Web Deployment Descriptor (web.xml) is updated ensuring that the Faces Servlet is present along with the specified:
- Faces Servlet Name
- Faces Servlet URL Mappings
- Context Params for Faces configuration file
- An empty Faces configuration file using the name and location specified by the user is created. If a file with that name already exists at that location, this step is skipped.
Related concepts