I have a managed bean with a method that returns a UIComponent,
sometimes a commandLink or a outputText.
public UIComponent getComponent ()
{
UIComponent link ;
if (this.isAction ()) {
link = new HtmlCommandLink ();
link.setTitle (this.title);
MethodBinding method = FacesContext.getCurrentInstance
().getApplication ().
createMethodBinding (this.value, null);
link.setAction (method);
}
else {
link = new HtmlOutputText ();
link.setValue (this.title);
}
return link;
}
Then, in the view i imagine something like that
:
<t:component value="#{managedBean.component}" />
is this possible or i have to create a custom component ???
thanks in advance, and sorry for my english mistakes.
--
View this message in context:
http://www.nabble.com/Newbie-question%3A-How-to-generate-a-jsf-component-dynamically-tf2743954.html#a7655989
Sent from the MyFaces - Users mailing list archive at Nabble.com.