Good to know. Btw what are the semantics of using mixed-scope managed properties inside each other?

Example:

 

Backing bean A has request scope

Backing bean B has application scope but contains a managed reference to A.

 

What am I obtaining when retrieving B.a?

Futhermore, in spring, you either have singletons or “created-every-time”, is it a best practise to emulate this? (i.e. all managed properties should either be scope none or scope equal to encapsulating bean)

 

Dhanji.


From: Craig McClanahan [mailto:[EMAIL PROTECTED]
Sent: Wednesday, June 21, 2006 8:59 PM
To: MyFaces Discussion
Subject: Re: managed properties


Actually, you're working too hard.  Just use:

    <value>#{businessDelegate}</value>

 

JSF IoC container is not that powerful, I prefer to use Spring and then use


You can accomplish that with standard managed beans my setting the <managed-bean-scope> on the "businessDelegate" bean to be "none".  This is like the create-every-time mode of Spring ... you always get a new instance each time the _expression_ is evaluated, and it is never placed into any scope.


Craig

 

This correspondence is for the named persons only.
It may contain confidential or privileged information or both.
No confidentiality or privilege is waived or lost by any mis transmission.
If you receive this correspondence in error please delete it from your system immediately and notify the sender.
You must not disclose, copy or relay on any part of this correspondence, if you are not the intended recipient.
Any opinions expressed in this message are those of the individual sender except where the sender expressly,
and with the authority, states them to be the opinions of the Department of Emergency Services, Queensland.

Reply via email to