xml-xmlbeans-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 26228] New: - Failure when used with xalan 2.5.2
Date Sun, 18 Jan 2004 07:59:57 GMT
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=26228>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=26228

Failure when used with xalan 2.5.2

           Summary: Failure when used with xalan 2.5.2
           Product: XMLBeans
           Version: unspecified
          Platform: Other
        OS/Version: Other
            Status: NEW
          Severity: Normal
          Priority: Other
         Component: XmlObject
        AssignedTo: xmlbeans-dev@xml.apache.org
        ReportedBy: mg@subscribe.audumla.net


XmlBeans sax content handler fails when used as a source for xalan 2.5.2. This 
is caused when the saver creates the xmlns attributes but does not assign a 
namespace or localname.
The following code seems to solve the problem

        private void addNamespaceAttr ( String prefix, String uri )
        {
            try
            {
                _contentHandler.startPrefixMapping( prefix, uri );
            }
            catch ( SAXException e )
            {
                throwSaxException( e );
            }

            if (prefix.length() == 0)
                _attributes.addAttribute( "http://www.w3.org/2000/xmlns/", 
prefix, "xmlns", "CDATA", uri );
            else
            {
                _attributes.addAttribute(
                    "http://www.w3.org/2000/xmlns/", prefix, "xmlns:" + 
prefix, "CDATA", uri );
            }
        }

- ---------------------------------------------------------------------
To unsubscribe, e-mail:   xmlbeans-dev-unsubscribe@xml.apache.org
For additional commands, e-mail: xmlbeans-dev-help@xml.apache.org
Apache XMLBeans Project -- URL: http://xml.apache.org/xmlbeans/


Mime
View raw message