Jaxen is an open source XPath library written in Java. It is adaptable to many different object models, including DOM, XOM, dom4j, and JDOM. Is it also possible to write adapters that treat non-XML trees such as compiled Java byte code or Java beans as XML, thus enabling you to query these trees with XPath too.

Getting Started

You can download Jaxen via the releases page.

You could try browsing the FAQ or the online JavaDoc.


XOM 1.1 bundles Jaxen 1.1.

Bob McWhirter talked about Jaxen at Software Development 2003 West.

Check out these Performance Benchmarks comparing dom4j and Jaxen against Xerces and Xalan.

Sun chose Jaxen for the XPath engine for the JSP Standard Tag Library (JSTL) and the Java Web Services Developer Pack 1.0 and 1.1.

Since the reference implementation of Java API for XML Messaging is based on dom4j and Jaxen, that means you can use Jaxen to query SOAP messages on the Java platform too!

Check out Elliotte Rusty Harold's book chapter on XPath and Jaxen

Alex Chaffee wrote XPath Explorer to help visualize results of XPath expressions.