|
Right if you want to have full control over the scope of Spring Managed
Beans then you'll have to go with the more complete integration offered
by the jsf-spring package. Although it's just occurred to me anther
option might be customize DelegatingVariableResolver to make a callback
to the bean, post-creation when the bean is manged by JSF. The only
problem I can see with this (apart from the fact that you'll have extra
code to maintain) is that the VariableResolver decorator will be called
on any access to the bean via EL not just creation, so you'll have to
add logic to somehow work out if this is creation or not - either in
the bean itself which would be simplest - or in the decorator. Worth a
thought. Duncan GroundBlog David Tashima wrote: Yes, I was thinking about that, but it seemed a bit hacky to me - especially since it depends on the order that the properties are set.Actually, you're right - having Spring manage it works, since it has application scope anyway. So if the scope had to be something more transient than application scope, I would have to use the jsf-spring package? -Dave On 6/16/05, Duncan Mills <[EMAIL PROTECTED]> wrote:David, Could you not do the initialision in the setter that is being used to inject the Spring managed value? The other option would be to let Spring manage this object instead as you do have a lot more flexibilty there - however option 1 seems simpler if it would work in this situation.. Duncan Mills www.groundside.com/blog David Tashima wrote: |
- Re: Initializing a managed bean (Spring integration) Duncan Mills

