Implementing AJAX Components in the JWL Framework
- Create a new Java class ThreeStringsConcatenatorBean.java with three variables: text1, text2, text3.
- In ThreeStringsConcatenatorBean.java, generate getter and setter methods for the variables. Add a new getConcatenateThreeFields() method that will concatenate text1, text2, and text3 and return the result.
- Select ajaxRefreshSubmitExample.jsp. Under the Page Data view, select Faces Managed Beans → New → Faces Managed Bean.
- Register the ThreeStringsConcatenatorBean JavaBean in faces-config.xml.
- Map fields in the JavaBean with fields in the JSP page by dragging fields from the bean onto the page.

Click here for a larger image.
Figure 11: Create New Java Class—ThreeStringsConcatenatorBean.java
Listing 6: Implementation Of getConcatenateThreeFields() Method
public String getConcatenateThreeFields() { return text1 + text2 + text3; }

Figure 12: Create a New Faces Managed Bean

Click here for a larger image.
Figure 13: Register a New Faces Managed Bean

Click here for a larger image.
Figure 14: Map Bean Fields to Input Field on the Page
0 Comments (click to add your comment)
Networking Solutions



Solid state disks (SSDs) made a splash in consumer technology, and now the technology has its eyes on the enterprise storage market. Download this eBook to see what SSDs can do for your infrastructure and review the pros and cons of this potentially game-changing storage technology.