axis-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dirk Reiss <d.re...@tu-bs.de>
Subject trouble with xmlns:xml
Date Sat, 13 Mar 2004 10:07:23 GMT
Hello,

i send a xml-document to an apache-axis-server. Axis provides the method
getAsDocument()
in several classes which itself uses xerces to convert content to a
Document.

When i have something like

<element xml:lang="en" xmlns:xml="http://www.w3.org/XML/1998/namespace">

in my document, i get the following exception:

org.xml.sax.SAXException: Fatal Error: URI=null Line=2: The prefix
"xmlns" cannot be bound to any namespace explicitly; neither can the
namespace for "xmlns" be bound to any prefix explicitly.
     at
org.apache.axis.utils.XMLUtils$ParserErrorHandler.fatalError(XMLUtils.java:624)
     at org.apache.xerces.util.ErrorHandlerWrapper.fatalError(Unknown 
Source)
     at org.apache.xerces.impl.XMLErrorReporter.reportError(Unknown Source)
     at org.apache.xerces.impl.XMLErrorReporter.reportError(Unknown Source)
     at
org.apache.xerces.impl.XMLNSDocumentScannerImpl.scanAttribute(Unknown
Source)
     at
org.apache.xerces.impl.XMLNSDocumentScannerImpl.scanStartElement(Unknown
Source)
     at
org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(Unknown
Source)
     at
org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown
Source)
     at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
     at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
     at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
     at org.apache.xerces.parsers.DOMParser.parse(Unknown Source)
     at org.apache.xerces.jaxp.DocumentBuilderImpl.parse(Unknown Source)
     at org.apache.axis.utils.XMLUtils.newDocument(XMLUtils.java:322)
     at
org.apache.axis.message.MessageElement.getAsDocument(MessageElement.java:688)

[snip] (some stuff from my classes)

As far as i can see there is no xmlns:xmlns=" ..." declaration in my
document, so this error should not occur as xmlns:xml is not necessary
but allowed according to w3c-errata.

So, is this a but in xerces or am I missing something?

Thanks in advance,

Dirk


Mime
View raw message