[jdom-interest] Resetting the Root Element

Sebastian Hinterwälder hintsn at idmt.fraunhofer.de
Mon Nov 5 08:41:45 PST 2007


I have a question concerning the root element of a normal XML document. 
Probably something like this already appeared in this list some time 
ago, but I don't get my problem solved so far.

I have a normal "ATOM feed" which looks something like this:

<?xml version="1.0" encoding="utf-8"?>
<!-- generator="FeedCreator 1.6" -->
<feed xmlns="http://www.w3.org/2005/Atom"
    <subtitle>IT-News fuer Profis</subtitle>

Now I want to set a different root element using JDOM. I already tried 
it by cloning the whole document but this doesn't work. A different 
solution for me would also be removing the namespaces from the root. I 
am quite new to JDOM - so I hope someone knows a solution!

Thanks in advance


More information about the jdom-interest mailing list