Pretty print xml & xsd in Java, BUT without any content change

时间:2017-06-09 12:52:31

标签: java xml xsd

I found a lot of similar questions here, but my major purpose is NOT TO CHANGE the content!!! I just want to indent and adapt blanks, but do not want to change the order or anything else inside the xml / xsd files.

I found a solution in shell: find . -name ".xml" -type f -exec xmllint --output '{}' --format '{}' \; find . -name ".xsd" -type f -exec xmllint --output '{}' --format '{}' \;​

But why is this not possible in Java?

0 个答案:

没有答案