We can add additional flexibility to WorldWind's XML output logic to allow for a bit more fine-grained control. The original pull-request (https://github.com/NASAWorldWind/WorldWindJava/pull/23) adds configuration that allows for XML output to be pretty-printed and to allow the XML-declaration to be emitted (useful for embedding WorldWind-produced XML in other XML documents). We can have a look at what @rougeSE did in the above-mentioned pull-request to get an idea of where to start with this.
We can add additional flexibility to WorldWind's XML output logic to allow for a bit more fine-grained control. The original pull-request (https://github.com/NASAWorldWind/WorldWindJava/pull/23) adds configuration that allows for XML output to be pretty-printed and to allow the XML-declaration to be emitted (useful for embedding WorldWind-produced XML in other XML documents). We can have a look at what @rougeSE did in the above-mentioned pull-request to get an idea of where to start with this.