JXPath 1.1 Release Notes
Most changes in 1.1 are in the internal implementation and do not affect
public APIs. However there are some new publicly visible features:
Full support for JDOM. Just like with DOM, if a JDOM node
is the root node of a JXPathContext, the implementation strictly follows
the XPath 1.0 standard. A JDOM node can also be a part of a mixed model,
i.e. the value of a property, variable, container, collection element
Pointer has an additional method: getNode(), which returns the raw
value without converting it to a primitive value. This makes
a difference when you are working with DOM/JDOM and want to obtain
the Node itself, not the textual value of the Node.
Support for DynaBeans
Refactored XML parsing by container to allow for alternate parsers.
All you do now is specify which model you want the container to use -
DOM (default) or JDOM. From that point the processing is transparent.
The format-number XSLT function is now supported.
In order to provide full conformance with the standard, we also
needed to introduce the format customization mechanism known in
XSLT as <xsl:decimal-format> (see
W3Schools tutorial). The new methods of JXPathContext:
getDecimalFormatSymbols() fulfill that requirement.
The attribute:: axis is now supported models other than
DOM/JDOM. For beans and maps it is interpreted the same way as
the "child::" axis.
In JXPath 1.0 you could only register DynamicPropertyHandlers for
concrete classes, now you can also register them for interfaces.
The implementation of setValue() has changed for DOM/JDOM
nodes. In JXPath 1.0 it would replace text in the element, but leave
sub-elements alone. The new implementation is more consistent: it
drops all subelements first. Also, if you pass a Node as the new
value, it will insert the Node in the tree.
If you need to evaluate multiple paths relative to a certain node
in the object graph, you can now create a relative JXPathContext.
Obtain the pointer for the location that is supposed to define
the relative context and then a relative context by calling
The JUnit tests for JXPath have been completely redisigned and
Great thanks to everybody who reported problems, helped to trace them,
suggested changed or simply provided encouragement. Special thanks to
- Trond Aasan
- Bjorn Bength
- Derek A. Bodin
- Stephen Colebourne
- Torsten Curdt
- Pierre Delisle
- Ruud Diterwich
- Peter Donald
- Kate Dvortsova
- Eduardo Francos
- dIon Gillard
- Mike Hogan
- Ivelin Ivanov
- Per Kreipke
- Kees Kuip
- David Li
- Ulrich Nicolas Lisse
- Costin Manolache
- Thorsten Mauch
- Craig R. McClanahan
- Markus Menner
- Daniel Michalik
- Steve Pannier
- Ed Peters
- Kenneth Petersen
- Ovidiu Predescu
- Erik Pugh
- Robert Rasmussen
- Vasco C. Rocha
- Francois Swiegers
- Joern Turner
- Knut Wannheden
- Andrew Wulf
- Jason van Zyl