Building user interface for web is always been discussed, advised, argued and even warned among the web developer community and user interface researchers. There are sites exclusively discussing User Interfaces for web sites and web based applications. User Interfaces (UI) design using leads to innovative thinking, and at the same time, to criticisms. An UI is needed to give the first impression, and an UI is is the foundation of success for web applications. Developers of Java has now got a new framework called Java server Faces(JSF) which can minimize their hurdles in excellent UI designing, and improve the applications overall values. Let us have a brief on JSF, which can guide you to start your own JSF writing.
Web page authors, Application developers, Component writers, Tools vendors are always needed good interface writing skills. In earlier days, there was a hard time for Java Developers to care about the Interfaces and Design templates. There was no much flexibility or design time tools that can support their needs to create the Interfaces, which the end-users like. Java developers need to take much effort to give good user interfaces for the applications they write.
Java developers has existing frameworks, Servlets and Java Server Pages (JSP) which gives the ability to build HTML-based Web applications using Java, but the servlet APIs and JSPs were foundational technologies, they left a lot to be done before a Web application could be considered complete. So mostly Java Web developers had to implement their own frameworks, including page navigation and reusable user interface (UI) components for the Web. There was no standard way to do this implementation easily and without a standard there was no advanced development tool support that offered a productive and visual way to develop Java-based Web applications.
UI designers still have to have much programming knowledge and thanks to Java Server Faces (JSF) which helps us to make the UI development life a lot easier.
In any application development project, interface is a frequent updated part, so we try to ease the changes in the interface as much as possible. In a development firm the members of the team have significantly different skill sets - server-side programmers, HTML coders, graphic designers, etc. for whom they want their work to be as independent as possible. This leads to a model-view-controller (MVC) design to separate the roles.
In many organizations, the development of a web application can work in this way: The designer creates a prototype, the HTML coder does everything in HTML, and the server-side programmer achieves the needed functionality in a server side programming language(JSP, PHP, or ASP etc.,). But this approach doesn't work mostly, in a No Problem state. The designer, when creating the prototype, is limited only by his or her imagination, inadvertently causing problems for the other participants, often forcing them to start from scratch when developing a new application.
Some one may say that such problems can be corrected using the existing frameworks and by using custom tags or XML/XSL transformations. But there are still problems persist with code reuse. Also for the web developer to know the button has been pressed, he has to analyze the HTTP request and try to determine what has happened. This is not ideal. The programmer shouldn't have to work so hard to figure out if a button, image, or hyperlink was clicked, or how these pieces were implemented in HTML. Ideally, the developer just wants to know that an event occurred. In other words, the developer should be able to see the web interface in terms of familiar high-level concepts.
JSF has the reusable server components for creating the Graphical User Interfaces. In JSF architecture, all components should inherit from javax.faces.component.UIComponent . Any page or screen of the application will consist of a set of such components. A set of hierarchically ordered components is called the JSF Tree or the View. With this tree of components we can understand the structure of the onscreen page. Each element of a tree is UIComponent , with some components being composites and thus having child components.
In JSF there is a set of standard components. According to Java specification request-127, The developer can create new components based on existing components (for example, by inheriting from UIOutput, which is a subset of UIComponent), or by a completely new subclass of UIComponent. To make creating components easier, it's possible to inherit from UIComponentBase, which contains default implementations for the methods in UIComponent.
JSF applications are straightforward and easy to implement. A JSF application is essentially a standard J2EE application with a set of required components:
JSF application UIs can also be constructed entirely from well-formed XML documents rather than JSP pages. For deployment, JSF applications do not require a specially configured run-time environment, but can be deployed standalone to any standard J2EE container such as Tomcat.
Frameworks like Ants and Struts provided some of this functionality, but JSF provides a greater range of client-side features. The open-source Apache Jakarta Struts project already has a JSF library (jakarta.apache.org/struts/proposals/struts-faces.html ) to make life easier for programmers who use Struts.
JSF promises to be not just another Java standard, So Java developer will find JSF as an easy way to start, no learning of a whole new concept, but just the prerequisites. Lotus Notes or IBM's WebSphere developers will be working with JSF as a beta JSF implementation was already shipping in IBM's WebSphere Studio 5.1.1 a few weeks before the Java Community Process gave JSF.
Also Sun's newest Java development tool, Java Studio Creator, now in its second beta, includes it. Excising J2EE developers can straight away start using JSF framework as it has been shipped with the newer versions of JDK. To use JSF, you'll need Java Development Kit (JDK) 1.3.1 or higher and Java Web Services Development Pack 1.3. It will run on Solaris 8 or higher, Windows XP, Windows 2000 or Red Hat Linux.