Skip to content

Java XML Parsing, Transforming, Printing, and Validating

License

Notifications You must be signed in to change notification settings

jcabi/jcabi-xml

Repository files navigation

Simple XML Parsing and Traversing, in Java

EO principles respected here DevOps By Rultor.com

mvn PDD status codecov Javadoc Maven Central

More details are here: xml.jcabi.com. Also, read this blog post: Java XML Parsing Made Easy.

It's a simple wrapper around DOM that makes XML parsing and printing easy and simple, for example:

XML xml = new XMLDocument(
  "<cart><item id="4">Coffee to go</item></cart>"
);
XML item = xml.nodes("//item[@id=4]").get(0);
String name = item.xpath("text()").get(0);
System.out.println(xml.toString());

How to contribute?

Fork the repository, make changes, submit a pull request. We promise to review your changes same day and apply to the master branch, if they look correct.

Please run Maven build before submitting a pull request:

mvn clean install -Pqulice