[jdom-interest] Removing empty nodes in a document?

Gary Udstrand GUdstrand at healthnexis.com
Wed Jul 18 08:49:13 PDT 2001

    I am creating an XML document that will be translated via Mercator.  The
Mercator mappers have told me that I need to remove all the empty nodes from
the document before it can be handed off to them, is this possible using

    I have also been told that all newlines have to be removed, including
the one at the end of the XML declaration.   I see in the javadoc that the
XML declaration is always printed on its own line, why?  

     Both of the above requests seem kind of unusual to me.  I can see
removing the empty tags and newlines to cut down file size but from what I
have been told Mercator has difficulty with XML documents that have not been
tailored as outlined above.  Is this normal? 


More information about the jdom-interest mailing list