Java
  Home arrow Java arrow Page 7 - Introduction to JavaServer Faces, Part 3
Dev Shed Forums  
Administration  
AJAX  
Apache  
BrainDump  
DHTML  
Flash  
Java  
JavaScript  
Multimedia  
MySQL  
Oracle  
Perl  
PHP  
Practices  
Python  
Reviews  
Security  
Smartphone Development  
Style-Sheets  
Web Services  
XML  
Zend  
Zope  
Mobile Linux  
App Generation ROI  
IBM® developerWorks  
Forums Sitemap  
E-Commerce Hosting  
Linux Web Hosting  
Managed Hosting  
Small Business Hosting  
VPS Hosting  
Weekly Newsletter

 
Developer Updates  
Free Website Content 
 RSS  Articles
 RSS  Forums
 RSS  All Feeds
Write For Us Get Paid  
Request Media Kit
Contact Us  
Site Map  
Privacy Policy  
Support  
 USERNAME
 
 PASSWORD
 
 
  >>> SIGN UP!  
  Lost Password? 
JAVA

Introduction to JavaServer Faces, Part 3
By: McGraw-Hill/Osborne
  • Search For More Articles!
  • Disclaimer
  • Author Terms
  • Rating: starstarstarstarstar / 20
    2004-03-22


    Table of Contents:
  • Introduction to JavaServer Faces, Part 3
  • Wrtiting the JSP Files for the Page Navigation Example
  • Creating the Application Configuration File for the Page Navigation Example
  • Compiling and Running the Page Navigation Example
  • Introducing the JSF Application Programming Interface (API)
  • javax Packages
  • More javax Packages

  • Rate this Article: Poor Best 
      ADD THIS ARTICLE TO:
      error-file:tidyout.log Del.ici.ous error-file:tidyout.log Digg
      error-file:tidyout.log Blink error-file:tidyout.log Simpy
      error-file:tidyout.log Google error-file:tidyout.log Spurl
      error-file:tidyout.log Y! MyWeb error-file:tidyout.log Furl
    Email Me Similar Content When Posted
    Add Developer Shed Article Feed To Your Site
    Email Article To Friend
    Print Version Of Article
    PDF Version Of Article

     
     
    ADVERTISEMENT


    Introduction to JavaServer Faces, Part 3 - More javax Packages
    ( Page 7 of 7 )

    The javax.faces.lifecycle Package
    The javax.faces.lifecycle package contains classes and an interface that have something to do with the request processing lifecycle. There are two classes in this package: Lifecycle and LifecycleFactory. As explained earlier in this chapter, the Lifecycle object is the object that processes a JSF request. The Lifecycle object is represented by the javax.faces.lifecycle.Lifecycle class. The LifecycleFactory class is responsible for creating a Lifecycle instance.

    The only interface in this package is ViewHandler. This interface defines a mechanism by which the Render Response phase of the request processing lifecycle can support different response-generation technologies. 

    The javax.faces.render Package
    The javax.faces.render package contains three classes: Renderer, RenderKit, and RenderKitFactory. A Renderer is responsible for converting the internal representation of a UI component into something that is understood by the JSF client. When JSF is used in a Web application, a Renderer sends HTML tags to the browser as the representation of a UI component’s state. A Renderer normally can render one UI component, so there are always many Renderer objects for the various standard UI components used in a JSF application.

    A RenderKit represents a collection of Renderer instances. The JSF implementation comes with the default RenderKit.The RenderKitFactory is a factory object that returns a RenderKit instance.

    Renderers are discussed in Chapter 12.

    The javax.faces.tree Package
    The javax.faces.tree package contains the Tree and TreeFactory classes. The Tree class represents a component tree. The TreeFactory is responsible for creating Tree instances.

    The javax.faces.validator Package
    The javax.faces.validator package contains the Validator interface that you implement to write your custom validator. It also contains a number of standard validator classes: DoubleRangeValidator, LengthValidator, LongRangeValidator, RequiredValidator, and StringRangeValidator. Validators and input validation are discussed in Chapter 9.

    The javax.faces.webapp Package
    The members of the javax.faces.webapp package are classes that are required for integrating JSF into Web applications. The most important class in this package is the FacesServlet class. An instance of this class is required by each JSF application to manage the request processing lifecycle. Its job description includes obtaining a FacesContext instance and passing it to the Lifecycle object for processing.

    Another member, UIComponentTag, is a base class that you need to extend to create a tag handler that handles a JSP custom action that is related to a UI component. You can see this class used in Chapters 12 and 13.

    Summary
    This chapter provided a gentle introduction to JSF. Its main objective was to give you the experience of running your first JSF applications. You got an idea of how JSF works, without going into all of the details yet. You will learn more about JSF processing in later chapters.

    In this chapter, you learned the most important characteristic of JSF applications that makes them different from other servlet/JSP applications: their event-driven nature. You also built three simple JSF applications that illustrate the component tree, event processing, input validation, and page navigation. The last section of this chapter offered a general overview of the JSF API, which you will be using to develop JSF components in the next chapters.

    Buy this book now!Remember: This is part three of the second chapter of JavaServer Faces Programming, by Budi Kurniawan (McGraw-Hill/Osborne, ISBN 0-07-222983). If you've enjoyed what you've seen here, click on the "Buy it now!" banner to pick up a copy today!
    Buy this book!



     
     
    >>> More Java Articles          >>> More By McGraw-Hill/Osborne
     

       

    JAVA ARTICLES

    - Exception Handling Techniques in Java
    - More About Multithreading in Java
    - The Basics of Multiple Threads in Java
    - Data Access Using Spring Framework JDBC
    - New Object Initialization in Java
    - Adding Images With iTextSharp
    - Adding Columns With iTextSharp
    - Creating Simple PDF Files With iTextSharp
    - The Spring Framework: Understanding IoC
    - Introducing the Spring Framework
    - Java Classes
    - Completing the Syntactic Comparison of Java ...
    - Syntactic Comparison of Java and C/C++
    - Java Statements
    - Conditionals, Expressions and Other Java Ope...





    © 2003-2009 by Developer Shed. All rights reserved. DS Cluster 1 Hosted by Hostway
    Stay green...Green IT