Agenda
• What is JSF?
• Rich Internet Applications (Web 2.0)
• JSF + AJAX = Enterprise RIA
• Examples
• What’s next and questions
What is JSF?
• Open source, server-side user interface component framework for Java-based Web applications
• Applications assembled out of UI components
• The standard technology for building enterprise Web applications today
Why Use JSF?
• Components, components, components
• Quickly build sophisticated UI
• Easy to use
• A standard, part of Java EE5
• Great community and industry support
AJAX (Web 2.0)
• Rich, interactive, and fast
• Desktop applications using Web delivery
• Basic ideas behind AJAX:
– Send only data that’s needed
– Update only a part of a page
• Thousands of consumer Web sites
• Enterprises have taken notice
• AJAX (JavaScript, XML, DOM ) programming is challenging
• Battling browser incompatibilities
Java Server Faces AJAX
Extends JSF to enable richer applications by seamlessly adding AJAX functionality
è JSF page with Ajax4JSF
<%@ taglib uri="https://ajax4jsf.dev.java.net/ajax" prefix="a4j"%>
<%@ taglib uri="http://java.sun.com/jsf/html" prefix="h"%><%@ taglib uri="http://java.sun.com/jsf/core" prefix="f"%><html><head><title>a4j Simple Demo</title></head><body><f:view> <h:form> <h:panelGrid columns="2"> <h:outputText value="Type the Text:" /> <h:inputText id=”txtName” value="#{bean.userName}"> <a4j:support event="onkeyup" reRender="repeater" /> </h:inputText><h:outputText value="Text in the AJAX Response:" />
<h:outputText id=”repeater” value="#{bean.userName}" /> </h:panelGrid> </h:form></f:view></body></html>Why Do You Need Ajax4jsf?
The answer to that question is simple (although it is more than one answer):
• If you need to develop modern, rich, dynamic, Web 2.0 applications using JSF, you
need Ajax4jsf!
• No other solution combines such powerful functionality in a single package to add
AJAX to your applications.
• No other solution allows you to combine the full power of JSF with a modern Web
2.0 interface.
• No other solution has such openness, such full compatibility with all standard JSF
implementations and component libraries.
• No other solution gives you such flexibility in look and feel.
• No other solution gives you this level of power to deliver results.
Conclusion
A components-based approach using JSF and Ajax4jsf is the best way for enterprises to
address the Web 2.0 challenge. To learn more about Ajax4jsf, go to Web site for the Ajax4jsf
project site at https://ajax4jsf.dev.java.net