Table listening to a Tree...
Hi,
I am new to ADF and I am trying to make a UI similar to the File Explorer demo of the ADF.
I have a Folder/File type of hierarchical objects and I want to show the tree in the left side of a splitter panel. When the user clicks on a node in the tree, I want to show/refresh a table that is displayed on the right side of the splitter panel with the contents of the folder clicked on the tree. Identical to the File Explorer. (I have not decided what to do when a leaf node is clicked. Is it ok to show the leaf nodes in the tree? That is another question)
I have successfully created a TreeModel extending a ChildPropertyTreeModel in which I have a method getTreeModel() which constructs statically a bunch of nodes and returns the root node.
I have overridden the method isContainer() to return TRUE if the current node's getChildren() method returns one or more nodes.
That is all I have in that bean.
In the JSFX file, I have created the required splitter panel with Tree on the left and a table on the right. I am successfully able to bind the tree to the TreeModelBean and able to see the tree populated nicely with the nodes on the left side of the splitter panel. But I honestly do not know how to bind the selected node to the Table so that when the user clicks a node, the table would refresh with the nodes contents.
Could any one throw some light on how to do that? What I am missing and How to bind the selected node's children to the table's collectionModel?
Any help would be appreciated.
Thanks in advance
Gopal
Edited by: Gopal Rao on Oct 1, 2008 4:52 PM