• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Component tree

 
Shahir Deo
Ranch Hand
Posts: 80
Hibernate Java Oracle
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Guys,

I am New to JSF Framework , I came across Component Tree , I understood That but how jsf creates component tree?
and What is Facescontext?
 
Tim Holloway
Saloon Keeper
Pie
Posts: 18277
56
Android Eclipse IDE Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
JSF is a very pure implementation of the Model/View/Controller architecture. In JSF, you design the Views using View Template Language (xhtml) - which is also known as View Definition Language. You design the Models as Backing Beans. The Controllers are part of JSF itself and you almost never write a Controller in JSF.

The Master Controller for JSF is the FacesServlet. It not only binds together the Models and Views, it accepts an incoming URL, strips it down to extract the View Resource Path ("filename") of the corresponding View, then it compiles the View Template to produce the Component Tree, which is the reference object for all of the other stages in the JSF lifecycle.

Note that once the Component Tree has been constructed, it is saved for processing postbacks from the client. This saves time. It also, however, means that the URL and the View Resource don't track in perfect synchronization, which is a feature of JSF that annoys many people.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic