Hi

What I did was extend TreeNodeBase and add a parent. Then I created a TreeList 
which extends ArrayList, which is used instead of List as a holder for 
children, which has a parent property. Then in the add method I set the parent 
property of any children that is added to it.

Hermod

-----Original Message-----
From: Dennis Byrne [mailto:[EMAIL PROTECTED]
Sent: Monday, January 30, 2006 5:25 PM
To: MyFaces Discussion
Subject: Re: Tree2 - getting parentnode


I ended up doing this by extending TreeNode, and adding a parent property.  In 
the backing bean, where you build the tree structure, just manually set the 
parent and you will be able to access it in the view with EL.

Dennis Byrne

>-----Original Message-----
>From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
>Sent: Monday, January 30, 2006 05:45 AM
>To: [email protected]
>Subject: Tree2 - getting parentnode
>
>Hi
> 
>Shaking the tree(2) here :)
> 
>Has there been any work done on this, or should I go ahead and implement my 
>own tree-model for now?
> 
>Hermod
>
>
>* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
>
>This email with attachments is solely for the use of the individual or
>entity to whom it is addressed. Please also be aware that the DnB NOR Group
>cannot accept any payment orders or other legally binding correspondence with
>customers as a part of an email. 
>
>This email message has been virus checked by the virus programs used
>in the DnB NOR Group.
>
>* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
>
>



* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *

This email with attachments is solely for the use of the individual or
entity to whom it is addressed. Please also be aware that the DnB NOR Group
cannot accept any payment orders or other legally binding correspondence with
customers as a part of an email. 

This email message has been virus checked by the virus programs used
in the DnB NOR Group.

* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *

Reply via email to