Convert a DOM tree to a string in a way that is not optimized for NITF and avoids some problems with using printToString on a generic XML document.
(Adapted from PrintUsingDOM utility's walk method)
@param node root element
@param xmlDocHead XML declaration tag (not printed if null or empty)
@param docTypeTag document type declaration (not printed if null or empty)
@return document string
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.