private void writeDocument(Document document, Writer writer) throws IOException {
        String v = document.getXmlVersion();

        writer.append("<?xml ");
        writer.append(" version='").append(v == null ? "1.0" : v).append("'");
        writer.append(" encoding='").append(encoding.name()).append("'");
        if (document.getXmlStandalone()) {
            writer.append(" standalone='yes'");
        }
        writer.append("?>").append(lineSeparator);

        NodeList nodes = document.getChildNodes();
        for (int i = 0, imax = nodes.getLength(); i < imax; ++i) {
            write(nodes.item(i), writer, 0);
        }
    }
Set the line separator that will be used when serializing documents.
<p>
If this is not called then the serializer uses a default based on the
{@code line.separator} system property. 

@param lineSeparator the line separator to set.
jme3-plugins/src/xml/java/com/jme3/export/xml/DOMSerializer.java