voyent
Getting the backing bean instance  XML
Forum Index -> General Help
Author Message
Andreh

Joined: 11/Dec/2006 00:00:00
Messages: 33
Offline


I'm thinking in a way, that I can recover a backing bean instance on runtime...
Let me explaim...

Think that I have a page and two backing beans..
I want to the backing bean number 1, have visibility on that second backing bean, recovering the instance of the back number 2 at runtime...

I'm just wondering if a could do that on icefaces, or maybe someone can guide me to find a solution in Jsf itself... or if someone made something like this...

Sorry if I'm posting in the wrong place, just searching for a solution for this idea!


philip.breau


Joined: 08/May/2006 00:00:00
Messages: 2989
Offline


Hi,

Have you tried something like this:

Application application =
FacesContext.getCurrentInstance().getApplication();
StyleBean styleBean =
((StyleBean) application.createValueBinding("#{bean}").
getValue(FacesContext.getCurrentInstance()));


Philip

.
 
Forum Index -> General Help
Go to:   
Powered by JForum 2.1.7ice © JForum Team