Java XML and JSON: Document processing for Java SE, Part 1
See the original posting on JavaWorld
XML and JSON are important to me, and I’m grateful to Apress for letting me write an entire book about them. In this Java Q&A post I will briefly introduce the second edition of my new book, Java XML and JSON. I’ll also present two useful demos that I would have liked to include in the book if I’d had space for them.
First, I’ll show you how to override Xalan, which is the standard XSLT implementation for Java 11, with an XSLT 2.0+ and XPath 2.0+-compatible alternative, in this case SAXON. Using SAXON for XSLT/XPath makes it much easier to access features such as grouping, which I’ll also demonstrate. Next, I’ll show you two ways to convert XML to JSON with Jackson: the first technique is data binding, the second is tree traversal.