-
1. Re: Conversational Scope with JavaBeans
christian.bauer Mar 6, 2008 2:30 PM (in response to rmcdonough)You can not use binding="#{foo}" to bind JSF UI components directly into conversation-scoped backing beans. The conversation is not available in the RESTORE VIEW phase, when the binding needs to be resolved.
-
2. Re: Conversational Scope with JavaBeans
rmcdonough Mar 6, 2008 3:18 PM (in response to rmcdonough)Ah, ok that makes sense. In the rich:dataTable declaration I was doing:
<rich:dataTable value="#{presentationAction.valueList}" binding="#{presentationAction.valueTable}"...
When I should be doing simply:
<rich:dataTable value="#{valueList}"...
The binding attribute shouldn't be required in this case since @DataModelSelection should be able to give me the correct selection? Just want to be sure.
So any reference to:
#{presentationAction}
Will always fail with conversation-scoped bean. This now makes sense. We'll see how I fare.
-
3. Re: Conversational Scope with JavaBeans
keithnaas Mar 6, 2008 3:29 PM (in response to rmcdonough)There is addressed in the doc section called 6.8. Conversational components and JSF component bindings
It shows a workaround you can use.
Good luck
-
4. Re: Conversational Scope with JavaBeans
nimo22 Jul 30, 2008 9:03 AM (in response to rmcdonough)Another workaround to use binding in association to the Conversation-Scope is:
Associate the Bean in faces-config.xml:
<managed-bean> <managed-bean-name>myBean</managed-bean-name> <managed-bean-class>myBean </managed-bean-class> <managed-bean-scope>session</managed-bean-scope> </managed-bean>
But I do not know, what Scope the Bean has after this. Session or Conversation?..but it works.
So I guess, the better solution is really to have an own class for the binding -attributes with Session-Scope and inject this in the Conversation-Scope.
-
5. Re: Conversational Scope with JavaBeans
nimo22 Jul 30, 2008 9:07 AM (in response to rmcdonough)You have to use Event instead of Session for the binding-class..
-
6. Re: Conversational Scope with JavaBeans
nimo22 Jul 30, 2008 9:24 AM (in response to rmcdonough)Can I use the Factory-Annotation to produce parts of the UI dynamically? Then I do not need the binding attribute..