You can generate a JavaServer Faces
(JSF) Web page from a BMS map set file, for use in a J2EE Web environment.
The generated Web page resembles the original BMS map set in terms
of the layout and appearance of fields.
Restriction: You can create a JSF Web page only in an
existing dynamic Web project. To create a new project, click and configure the project as needed.
Using either of the following methods to invoke the Generate Web
Pages wizard.
- In the Outline view, complete the following steps:
- Right-click the map set that you want.
- Select Generate JSF Web pages.
- In the Navigator view, complete the following steps:
- Select the map set (.BMS) file.
- Right-click, and in the pop-up menu select .
In the Generate Web Pages wizard, configure the JSF options:
- Select the maps that you want, and click Next.
- If you have enabled bidirectional support, you can now configure
additional settings. See Bidirectional Web page generation options for
details.
Important: If you select multiple bidirectional
attributes while generating a JSF page, script errors might prevent
the JSF page from being executed. To clear such script errors, you
must manually edit the JSF page.
If you are not working with
bidirectional maps, proceed to the next step.
- For the Folder value, specify the destination
dynamic Web project. The location must be in the Web Content directory
within the project.
- To set the Package value, double-click
the name of the package that you want for the Java™ Beans.
- Click Finish.
For each map, the Generate Web Pages wizard generates the following
components in the Web project directory:
- A .JSP file in the WebContent directory
- A *Bean.java file in the directory (where * is the name of the map selected
in the wizard)
- A *Page.java file in the directory (where * is the name of the map selected
in the wizard)
JSF tags are used in the generated Web page. The map set fields
are marked in the following manner:
- Named fields are represented with a JSF tag.
- Named input fields are represented with an inputText tag.
- Named output (protected) fields are represented with an outputText tag.
- Unnamed fields a represented as static text.
- Unprotected, named fields marked with an intensity of Dark are
represented with a JSF password tag.
The following display attributes are represented on the generated
Web page:
- Color
- Reverse
- Underline
- Blink
- Outline
The Faces configuration file is updated (or created, if necessary)
for each generated JSF page. This configuration file is responsible
for managing the mappings between JSF pages and their associated Java beans, and for controlling
the flow between pages. Because flow cannot be determined at this
point in generation, no navigation rules will be generated.
For more information about JavaServer Faces,
see the Rational® Developer
documentation.