• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • Ron McLeod
  • paul wheaton
  • Jeanne Boyarsky
Sheriffs:
  • Paul Clapham
  • Devaka Cooray
Saloon Keepers:
  • Tim Holloway
  • Roland Mueller
  • Himai Minh
Bartenders:

Is FacesContext an object for entire aplication, or it's instantiated for each jsf page?

 
Ranch Hand
Posts: 147
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Is FacesContext an object for entire aplication, or it's instantiated for each jsf page?
 
Greenhorn
Posts: 15
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator


FacesContext object is created for entire application, and it handle multiple faces requests.


Thanks

A.Viswanath Yadav
 
Saloon Keeper
Posts: 28706
211
Android Eclipse IDE Tomcat Server Redhat Java Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

viswanath yadav wrote:

FacesContext object is created for entire application, and it handle multiple faces requests.


Thanks

A.Viswanath Yadav



No.

The FacesContext is created and destroyed on every JSF page request. In between page requests, it doesn't exist at all.

One of the more common problems people have with JSF, in fact, is that they attempt to access the FacesContext while handling a non-JSF request such as in a servlet, non-JSF JSP or Struts Action. They fail on a NullPointerException.

JSF is not a "Master Control Program".
 
Don't get me started about those stupid light bulbs.
reply
    Bookmark Topic Watch Topic
  • New Topic