Hello Mike,
  sorry for previous post...i pressed 'send' by mistake
dunno if you know it already, but have you checked the jsf-spring project
@sourceforge?
 
it integrates Spring & JSF perfectly and i am sure it does what you
want..
 
thanks and regards
 marco

 
On 10/26/05, Mike Kienenberger <[EMAIL PROTECTED]> wrote:
I've been reviewing open issues with my current application, and some
of them seem to deal with using Spring.  This is kind of frustrating
because I'm finding that JSF managed beans do ALMOST everything I want
without Spring, except for providing a
InitializingBean.afterPropertiesSet() method call after a new bean's
properties have been set.

So after pondering it for a bit, it occurred to me that there's no
reason why support for this interface (repackaged for MyFaces) can't
be added to the org.apache.myfaces.el.VariableResolverImpl or to the
org.apache.myfaces.config.ManagedBeanBuilder class.

It seems to me that modifying one of the above classes to call the
below code would provide this functionality in a backward-compatible
way that does not affect the TCK.

if (newBean instanceof InitializingBean)
((InitializingBean)newBean).afterPropertiesSet();

This could be done either as the last line in
ManagedBeanBuilder.buildManagedBean() or right after the call to
buildManagedBean() in VariableResolverImpl.resolveVariable .

Unfortunately, I can't see a way to adding this functionality cleanly
as a generic JSF tomahawk extension, so it would have to remain a
MyFaces-only feature.

Thoughts?

Reply via email to