1. How to show the root node?
2. How come my tree node is shown as a toString() of that node class, instead of the name of that class.
<rich:tree style="width:300px" value="#{treeBean.data}"
var="item">
<rich:treeNode type="root">
<h:outputText value="#{item.type}" />
</rich:treeNode>
<rich:treeNode type="child">
<h:outputText value="#{item.name}" />
</rich:treeNode>
Since I did specified a outputText treeNode for the "root", how come it is not showing.
For my tree node class with a type "child", I do have a getName(), setName() which should return a nice string instead of toString() of that class. But why it is showing toString()?
1. Tree component shows and processes children of the root node in order to have multi roots.
2. Your tree component setup uses built-in default tree node representation. Consider using "nodeFace" attribute. Please refer to UG for more.