JSF Framework Services or JSF Architecture:
- JSF framework is responsible for interacting with client devices.
- It provides tools for typing together the visual presentation, application logic, and business logic of a web application.
- However, the scope of JSF is restricted to the presentation tier.
- Database, Web Services, and other backend connections are outside the scope of JSF.
- The JSF framework provides the following services…
- MVC Architecture
- It includes three terms: Model, View, Controller
- Model means required data in a particular problem domain.
- Views means web application display.
- JSF connects the view and the model.
- Exa: h:inputText value=”#{user.name}”
- The JSF implementation operates as the controller that reacts to the user by processing actions and value change events that update the model or view.
- Exa: h:commandButtonvalue="Login"action="#{user.check}"
- Data Conversion
- Users enter data into web forms as text.
- Business object want data as numbers, dates or other data types.
- Validation and error handling
- JSF makes it easy to attach validation rules for fields such as “this field is required” or “this field must be number”.
- When users enter invalid data, you need to display an appropriate error message.
- Internationalization
- JSF manages internationalization issues such as character encodings and the selection of resource bundles.
- Custom Components
- Component developers can develop sophisticated component that pages designers simply drop into their pages.
- Exa: Calendar component
- AJAX Support
- JSF provides a standard AJAX communication channel that transparently invokes server side actions and updates client side components.
- Alternative renders
- By default, JSF generates markup for HTML pages.
- But it is possible to extend the JSF framework to produce markup for another page description languages such as WML.
Tags:
Java