Don't understand NodeModel.get with XML

"Ista Pouss" <[email protected]>
Newsgroups gmane.comp.web.freemarker.user
Message-ID <[email protected]>
Hi,

If I do that :

       String txt = "<root><a/><b/></root>";
        NodeModel mod = NodeModel.parse(
                new InputSource(new StringReader(txt)));
        System.out.println("hope it's root ? = "+mod);
        System.out.println("hope it's a ? = "+mod.get(0));
        System.out.print("hope it's b ? = "+mod.get(1));


I see on console :

hope it's root ? = freemarker.ext.dom.DocumentModel@108786b
hope it's a ? = freemarker.ext.dom.DocumentModel@108786b
hope it's b ? = null

It's not what I expected. What I don't understand ? How to get something
equivalent to "root, "a" and "b" ?

Thanks for your help.

-------------------------------------------------------------------------
This SF.net email is sponsored by the 2008 JavaOne(SM) Conference 
Don't miss this year's exciting event. There's still time to save $100. 
Use priority code J8TL2D2. 
http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone

_______________________________________________
FreeMarker-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/freemarker-user
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.