[ http://issues.apache.org/jira/browse/COCOON-1876?page=comments#action_12442172 ] Don Grodecki commented on COCOON-1876: --------------------------------------
[[ Old comment, sent by email on Tue, 11 Jul 2006 07:42:25 -0500 ]] Thank you! - Don > XMLDBTransformer blows up Saxon > ------------------------------- > > Key: COCOON-1876 > URL: http://issues.apache.org/jira/browse/COCOON-1876 > Project: Cocoon > Issue Type: Bug > Components: Blocks: XML-DB > Affects Versions: 2.1.9 > Reporter: Don Grodecki > Assigned To: Antonio Gallardo > Fix For: 2.2-dev (Current SVN), 2.1.10-dev (current SVN) > > > The XMLDBTransformer blows up Saxon, which does not like null URIs. The > following fix seems to work, replacing null in the first parameter to > addAttribute with "". > // Report result > AttributesImpl attrs = new AttributesImpl(); > attrs.addAttribute("", XMLDB_QUERY_OID_ATTRIBUTE, > XMLDB_QUERY_OID_ATTRIBUTE, "CDATA", this.key); > attrs.addAttribute("", XMLDB_QUERY_TYPE_ATTRIBUTE, > XMLDB_QUERY_TYPE_ATTRIBUTE, "CDATA", this.operation); > attrs.addAttribute("", XMLDB_QUERY_RESULT_ATTRIBUTE, > XMLDB_QUERY_RESULT_ATTRIBUTE, "CDATA", result); > The API being called is the SAX org.xml.sax.ContentHandler.createElement(). > From the Interface definition at http://www.saxproject.org/apidoc/index.html: > "Parameters: > uri - the Namespace URI, or the empty string if the element has no Namespace > URI or if Namespace processing is not being performed > ..." > Note that a null value is not specified as one of the options: > Both the versions that I have, which are saxon8 (jar contents dated > 4/7/2005) and saxonB-8.7.3 (the latest), blow out with a > NullPointerException. > I have used Saxon quite a bit, for XSLT 2.0, and the only calls to Saxon > with null URIs have been from the XMLDBTransformer. -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira
