• 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
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Application scope attribute listener

 
Ranch Hand
Posts: 75
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I have a JSF application. In the faces-config I have defined


then I created a class (implementing the proper methods)


and I declared it in the web.xml



The question is:
Why I cannot see the appHandler class added to the Application scope?

in the ServletContextAttributeListener.attributeAdded method I have implemented simple code like


but no messages about the appHandler appear. Hints?
 
Sheriff
Posts: 14691
16
Eclipse IDE VI Editor Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Your message is not related to SCWCD, so I move it to a relevant forum.
 
Ranch Hand
Posts: 36
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Maurizio Nagni:
I have a JSF application. In the faces-config I have defined


then I created a class (implementing the proper methods)


and I declared it in the web.xml



The question is:
Why I cannot see the appHandler class added to the Application scope?

in the ServletContextAttributeListener.attributeAdded method I have implemented simple code like


but no messages about the appHandler appear. Hints?




Managed beans will only be created the first time they
are referenced within a view (i.e. #{appHandler}). This
is why your attribute listener isn't printing anything.
 
This tiny ad will self destruct in five seconds.
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic