Creating a Web Module Project

To add and edit Web resources for your car rental application, you will first create a Web Module project called QuickCarRentalWeb. Since the bean classes and auxiliary classes from the EJB Module project are to be referenced in the Web resources, you will need both, to enter the EJB Module project QuickCarRentalEjb and the Java project Helperclasses in the project dependencies.

Prerequisites

You have created the entity bean QuickBookingBean and the stateless session bean QuickOrderProcessorBean in the project QuickCarRentalEjb.

You have already created the Java project Helperclasses.

Procedure

Creating the project structure

...

       1.      Choose File ® New ® Project to start the New Project wizard.

       2.      In the wizard, select the J2EE category (in the left pane), followed by Web Module Project (in the right pane). Choose Next.

       3.      Give your Web Module project the name QuickCarRentalWeb and leave the default settings for Project contents unchanged.

       4.      Choose Finish.

The wizard generates a initial project structure for the new Web Module project QuickCarRentalWeb. It already contains the two deployment descriptors web.xml and web-j2ee-engine.xml.

Specifying the project dependencies

For the build path, both the Java project Helperclasses and the EJB Module project QuickCarRentalEjb are to be referenced in the new project.

...

       1.      In the J2EE Explorer, select the project node QuickCarRentalWeb and open the context menu.

       2.      Choose Properties.

       3.      Choose Java Build Path in the left frame. In the right frame, choose the Projects tab.

       4.      Select the projects Helperclasses and QuickCarRentalEjb.

       5.      Confirm with OK.

Next step:

Creating the JSP quickCarRentalView