Using WebSphere Studio V5.1.1 to develop JSF applications: part 4th

Source: Internet
Author: User

This series of articles shows the characteristics of the Java™server Faces Technologypreview in Websphere®studio V5.1.1, which is the 4th part of the paper.

In part 3rd of the article series, we saw how JSF applications use Service data Object (SDO) technology to access data. In this article, we'll see how JSF leverages the existing Java EE technology. We will create a JSF page that invokes the existing EJB application and use Javabeandata control to display the EJB invocation results, taking into account the RAD nature of JSF. In addition, we will use the Quick edits view to write the Action Handler to invoke an existing stateless session bean.

To complete these exercises, you need to download the information contained in this article. In case you haven't finished the 3rd part, the download file contains the solution; Please import the EAR file as described in part 3rd. To run the example, you also need to create the database as described in part 3rd, and after you import the solution, run the application in the method described in the last section of part 3rd, so that you can create the JDBC data source in the Server Configuration for this exercise.

Import and install STOCKSYSTEMEJB

Now let's create the next JSF results page for the stock Data page created in part 2nd. First we import the existing EJB JAR file and then create a JSF page that displays the results.

To import an EJB JAR file and make it part of an existing EAR file, you need to perform the following steps:

Select File => Import in the WebSphere Studio application Developer (hereafter referred to application Developer).

Figure 1. Application Developer File Menu

Select EJB JAR file, and then click Next.

Figure 2. File Import dialog box

Navigate to C:\JSFArticleSeries\Part4\StockSystemEJB.jar. The Project name should be STOCKSYSTEMEJB. Select the existing ear file stocksystemear. (You must explicitly select an existing EAR; it is stocksystemejbear by default, which is likely to be misleading.) ) Click Finish.

Figure 3. EJB Import

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.