JSF decreases the effort to build and maintain applications, which will run on a Java application server and render application UI on to a target customer. JSF facilitates Web application development by Giving reusable UI components, Making simple data transfer among UI components, Managing UI state across various server requests, Enabling the implementation of custom components and Wiring client-side event to server-side application code.
JSF provides multiple rendering capabilities that allow JSF UI components to render themselves differently depending on the client types.
Tag attributes are fully dynamic and automatically map to properties, attributes moreover ValueExpressions on. Richfaces supports multiple libraries for various UI components and ajax. Moreover, JSF allows developing tools that simplify coding web-based Java applications.
Submit Next Question. By signing up, you agree to our Terms of Use and Privacy Policy. Forgot Password? This website or its third-party tools use cookies, which are necessary to its functioning and required to achieve the purposes illustrated in the cookie policy.
Since JSF 2. JSP technology is part of the Java technology family. JSP pages are compiled into servlets and may call JavaBeans components beans or Enterprise JavaBeans components enterprise beans to perform processing on the server. As such, JSP technology is a key component in a highly scalable architecture for web-based applications.
A: JavaServer Faces technology is a framework for building user interfaces for web applications. JavaServer Faces technology includes:. A set of APIs for: representing UI components and managing their state, handling events and input validation, defining page navigation, and supporting internationalization and accessibility.
JSF is targetted for richer event based Web applications. JSF page is converted to components tree by specialized FacesServlet and it follows component lifecycle defined by spec. It uses XML for view templates. FacesServlets is responsible for processing requests and sending required view templates, creating component trees, processing events and rending response to the clients. The state of the components is saved which is retrieved before creating another view. On the other hand, JSP is a request-driven technology and it is translated into servlets during the runtime.
Even though it is request-driven, instead of using it independently, it can be used with view component of any server-side MVC design. The model could be JavaBeans while the controller can be Java Servlet.
The features present in JSF makes it suitable for presentation-type applications whereas JSP is more suitable for service-related applications. As a matter of fact, it is its integration with Ajax that makes it more popular than JSP. It is important to understand the working and flow of the two for the same web application to understand the differences. In JSP, one component has minimal impact on the other component.
Therefore, you can create new views without having to write the model. Therefore, the application can be more flexible. But when it comes to complication web applications, it is difficult to maintain the structure as it is the case with JSP while developing small-scale applications. There can be code duplication and the structure can become a mess and maintenance can be difficult.
Since JSP is a core technology, you can have different developers for different components but you have to be careful when it comes to integration as it can get messed up.
0コメント