Title: Message
Any attempt to navigate with further execQuery on a document returned from .copy() results in an exception in Saxon. There just doesn't appear to be any good way to work with copies or document fragments from execQuery. I will follow-up with code and examples in Jira (which I really don't know anything about) Can you help me here?
-----Original Message-----
From: Yana Kadiyska [mailto:[EMAIL PROTECTED]
Sent: Friday, August 05, 2005 2:47 PM
To: [email protected]
Subject: RE: execQuery() Casting to strongly typed XmlBean - ClassCastException

XQuery results are not typed...You can use changeType to type the result yourself, but only in the case that the result has a DocumentType corresponding to it. We are looking into improving that behaviour - if you wish to open a Jira bug with an example, that would be great.

 

Alternatively, can you use XPath and the .copy() method on the result?

 

-Yana

 


From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
Sent: Friday, August 05, 2005 7:20 AM
To: [email protected]
Subject: execQuery() Casting to strongly typed XmlBean - ClassCastException

 

Hi XmlBeaners,

   Is it possible with xmlbeans-2.0.0 to issue "execQuery(myQuery)" and cast it to a strongly typed XmlBean? Seems like this is only possible with "selectPath(myQuery)". Even when I use a Factory.parse method on the XML String fragment returned from execQuery, the XML will not validate? Any reason why?

 

My motivation for a fragment with XQuery is returning just a portion of XML that I'll further parse in a multi-threaded application. So I don't want to be working with the original store returned by selectPath.

 

Thanks,

Brian

Reply via email to