-
1. Re: When is outjection done?
echnaton Jan 3, 2007 3:17 PM (in response to vk101)i had the same error and i think i made it go away with required=false though this should only be important to the time when the variable is outjected.
afaik outjection is done after invocation of a method of the component but it looks like it is outjected as well after the component has been created -
2. Re: When is outjection done?
hstang Jan 3, 2007 3:21 PM (in response to vk101)I had @Out on a property but then got a org.jboss.seam.RequiredException "Out attribute requires value for component". So I changed it to @Out(required=true) and the exception went away.
Shouldn't it be changed to @Out(required = false) to get rid of the exception?
required = true is default with @Out. Anytime the owning component is accessed, and requires an outjection, the assertion will be made. This can happen during invoke application (jsf request) or render phase (initializing a data model via @Factory) -
3. Re: When is outjection done?
vk101 Jan 3, 2007 3:36 PM (in response to vk101)hstang, you're correct, I meant to say required=false in my original post.
You said "anytime the owning component ... requires an outjection, the assertion will be made". When does it require outjection? You mentioned it's during invoke application or render phase, so is it correct for me to believe that it's only when an action method is accessed rather than just get/set a property upon first page access? -
4. Re: When is outjection done?
hstang Jan 3, 2007 3:46 PM (in response to vk101)I only know three phases off the top of my head(updatemodel, invoke application, and render phase), but I would imagine that for all 6 phases in JSF, if a Seam component is accessed and requires an outjection, then the assertion (be it false or true) will be made.
action method (via h:commandButton) is part of the invoke application phase.
get and set property happens during render phase and update model phases. So all those cases need to be taken to account -
5. Re: When is outjection done?
vk101 Jan 3, 2007 4:03 PM (in response to vk101)Well I'd imagine that required=false would be needed a LOT more often if outjection would be done after the first Seam phase...?
Anybody know with certainty about this issue? -
6. Re: When is outjection done?
norman.richards Jan 3, 2007 4:22 PM (in response to vk101)Outjection is done after any access to a component. The @Intercept annotation can limit this to only certain phases.