Releases: jcabi/jcabi-xml
Releases · jcabi/jcabi-xml
XSL and XSLDocument
A new class and a new interface added in this version, XSLDocument
and XSL
respectfully. Transformation of XML is as easy as this:
XML first = new XMLDocument("<hello/>");
XML second = new XSLDocument(xsl).transform(first);
Conditional printing of documents and nodes
This version prints documents and nodes differently. For example:
XML xml = new XMLDocument("<root><name>John</name></root>");
System.out.println(xml);
will output:
<?xml version="1.1"?>
<root><name>John</name></root>
While this code:
XML xml = new XMLDocument("<root><name>John</name></root>");
System.out.println(xml.nodes("/root").get(0));
will output (mind the absence of XML declaration):
<root><name>John</name></root>
First stable version
First stable version that enables parsing and printing of XML documents:
XML xml = new XMLDocument("<hello><foo>hey</foo></hello>");
System.out.println(xml.nodes("/hello/foo").get(0));
will output:
<foo>hey</foo>