I've posted alpha 5 of XOM, my tree-based API for processing XML with Java. Beta status is not far away. Alpha 5 makes no backwards incompatible changes to the published API. Changes since the previous release include:
The ParsingException
and ValidityException
classes now have getURI()
methods that return the
URI of the document whose error caused the exception.
The test suite now runs the OASIS Microsoft and Xalan XSLT tests
Improved compatibility with Java 1.2
Improved compatibility with recent releases of Xalan, including those bundled with JDK 1.4.2_03 and later
I had a real revelation while talking about XOM at Extreme Markup Languages last week. As Larry Wall is fond of saying, "Easy things should be easy, and hard things should be possible." The revelation I had was that Wall's principle is almost tautological. What's easy and what's hard are functions of what the language allows and enables. A different language or API can make different tasks easy or hard. XOM is not designed around Wall's principle. Instead it follows what I autonymously call Harold's principle: The right things should be easy, and the wrong things should be difficult to impossible. In other words, XOM is designed to make it easy to process XML as it was intended to be processed (e.g. using elements, attributes, and mixed content) and difficult to impossible to process using the wrong techniques (e.g. treating CDATA sections, attribute order, and encoding as semantically significant).
The Jakarta Apache Project has released JXPath 1.2, a class library that "applies XPath expressions to graphs of objects of all kinds: JavaBeans, Maps, Servlet contexts, DOM etc, including mixtures thereof." According to the release notes:
Most changes in 1.2 are in the internal implementation and do not affect public APIs. However there are a couple of publicly visible features:
- Namespace registration. Namespace URIs can now be associated with prefixes at the level of JXPathContext.
- JXPathContext has two new convenience methods:
selectNodes
andselectSingleNode
.
- Type conversion is integrated with BeanUtils.
This release also includes countless bug fixes and implementation improvements.