Bryan, XMLBeans 2.4.0 supports Saxon 9 and has been tested specifically with Saxon 9.0.0.4; it does not support Saxon 8 because of incompatible API changes from Saxon 8.8 to 9.0. XMLBeans 2.3.0 supports Saxon 8.8, as you know. The behavior you describe sounds like a bug. Please open an issue in JIRA. Thanks, Wing Yew
-----Original Message----- From: Worrell, Bryan A. [mailto:[email protected]] Sent: Friday, May 22, 2009 11:24 AM To: [email protected] Subject: RE: xpath on copy of an object fails Hi, I made a mistake in my email--I was using Saxon 9.0.0.4 along with XMLBeans 2.4.0 and not Saxon 8. When I used XMLBeans 2.3.0 along with Saxon 8.8 the selectPath() behaves properly when applied to a copy() of an XMLBeans derived class. So in my example the following XMLBeans-Saxon pairings failed: XMLBeans 2.4.0 and Saxon 9.0.0.4 XMLBeans 2.4.0 and Saxon 9.1.0.6 Behaved properly: XMLBeans 2.3.0 and Saxon 8.8 I get exceptions thrown when I try to pair XMLBeans 2.4.0 to Saxon 8.8 and execute selectPath()--is this even possible or does it rely on Saxon 9? I don't know if my issue is a Saxon problem or an XMLBeans problem... Thanks, Bryan Worrell __ Bryan Worrell The MITRE Corporation [email protected] >-----Original Message----- >From: Worrell, Bryan A. [mailto:[email protected]] >Sent: Thursday, May 21, 2009 10:12 AM >To: [email protected] >Subject: xpath on copy of an object fails > >Hi, > >I am using XMLBeans 2.4.0 with Saxon 8 for this example: I am having a >problem when it comes to doing a selectPath(...) on a copy() of an >object and can't figure out why this is happening. ApplicationType is >an XMLBeans scomp derived class. The ApplicationType object being >passed in has a Name child element. > ><ApplicationType id="1"> > <Name>foobar</Name> > <!-- More Elements --> ></ApplicationType> > > >public void confuseDeveloper ( ApplicationType app ) { > String xPath = "$this/*:Name"; > > XmlObject[] xmlobjs = app.selectPath( xPath ); > System.out.println( xmlobjs.length > 0 ); // prints "true" like it >should > > ApplicationType tmpApp = (ApplicationType)app.copy(); // make a deep >copy > > xmlobjs = tmpApp.selectPath( xPath ); > System.out.println( xmlobjs.length > 0 ); // prints "false" ...this >is wrong > logger.debug( tmpApp.getName() ); // prints out "foobar" >} > > >I have tried different ways of making a copy of the ApplicationType >object but always have the same results... Any ideas as to why the >second xPath is failing? > >Thanks, >Bryan Worrell > >__ >Bryan Worrell >The MITRE Corporation >[email protected] > > > > > >--------------------------------------------------------------------- >To unsubscribe, e-mail: [email protected] >For additional commands, e-mail: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]

