Hey, what is up with the posts and followups with microscopic fonts? Do you guys run your resolution at 640x480 or something?

On Sep 16, 2008, at 3:59 PM, Michael Kay wrote:

The iterator() method of the XQueryEvaluator class returns an iteration of XdmItem objects. If your query selects nodes, then the XdmItem will always be an XdmNode. If you need to drill down from this, XdmNode.getUnderlyingNode() returns a NodeInfo object, and if the result is actually a JDOM node then you can cast the NodeInfo to VirtualNode and call its getUnderlyingNode() method to get to the JDOM level.
I'm considering providing more direct support in s9api for external object models in a future release, but I wanted to take my time and think carefully how best to do it. It will certainly be more type-safe than the JAXP approach. This will be a lot easier once I'm freed from the constraints of supporting JDK 1.4.
Michael Kay

From: saxon-help-bounces@lists.sourceforge.net [mailto:saxon-help-bounces@lists.sourceforge.net] On Behalf Of Baxter, Frank (LNG-CON)
Sent: 16 September 2008 15:30
To: saxon-help@lists.sourceforge.net
Subject: [saxon] Returning JDOM Elements from an XQuery

I've been able to return the XPath results as Elements by doing this:
      XPathExpression expression = thePathEvaluator.createExpression(query);
      return (List<Element>) expression.evaluate(myDocumentWrapper);
I've been unable to figure out how to do something similiar with XQueryExecutable.  How do you return the XQuery results as a list of org.jdom.Element objects?
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
saxon-help mailing list archived at http://saxon.markmail.org/