Hi Dennis,
thank you for getting back to me on this.
the details is like this: when the button is clicked, a brand new XML Document is fetched, and the root node in our own implementation of the TreeModel is updated to the new Document node. Since the root node is also our implementation of the TreeNode, it parses the XML Document and populates its children. so I believe we are unmarshalling in once place.
In fact, when the button is clicked, there is a brand new XML document to populate the tree. The tree is for displaying only, so JSF component -> XML will not be needed.
however, according to our log, the unmarshalling didn't have any problems because the new nodes in the XML are being parsed and processed in our TreeNode implementation, but for whatever reason there might be, the Tree just wouldn't re-render to reflect the new Document. Any ideas? Thanks!
On 6/8/06, Dennis Byrne <[EMAIL PROTECTED]> wrote:
Hello Mr. Bear,
Try moving all unmarshalling code ( XML -> JSF component ) to one place. Call this method before the page is rendered, as well as after each change to the XML document. A more sophisticated solutions might be to unmarshall once, allow the user to manipulate the JSF component, and use a marshall step ( JSF component -> XML ) to complete the "unit of work".
Dennis Byrne
>-----Original Message-----
>From: Jim the Standing Bear [mailto:[EMAIL PROTECTED]]
>Sent: Thursday, June 8, 2006 11:51 AM
>To: 'MyFaces Discussion'
>Subject: how to refresh an (old) tree?
>
>I have yet another question on the old tree. How do I get it to refresh?
>Our code is supposed to display the contents of an XML document in a tree.
>We have written our own java classes to implement both the TreeModel and
>TreeNode interfaces. When a button is clicked, the contents of the XML
>Document changes, the tree is supposed to reflect the changes.
>
>However, the problem is that the tree displayed in the web browser doesn't
>re-render. By looking at the log, the new XML Document gets parsed and
>processed in our own TreeModel and TreeNode implementations, however, the
>tree just never gets re-rendered and still displays the stale Document.
>
>How do I overcome that? thanks!
>
>--
>--------------------------------------
>Standing Bear Has Spoken
>--------------------------------------
>
--
--------------------------------------
Standing Bear Has Spoken
--------------------------------------

