axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "James M Snell" <>
Subject Re: Looking to remove dependency on xalan...
Date Wed, 06 Jun 2001 16:47:19 GMT
SAX2 fires off the startPrefixMapping event in the ContentHandler... these 
provide the prefix+namespace information... the only thing is that the 
startPrefixMapping events for a given element are fired before the 
startElement event for that element.  In other words: given the element 
<bob xmlns:t="leroy" /> the order of events is: 

     startPrefixMapping("t", "leroy")
     startElement("", "bob", "bob", attrs)

Which means, when we want to serialize the namespaces/prefixes, we gotta 
buffer the prefix mappings and hold on to 'em until the startElement event 

Now, I do not recall having this problem when using the 
org.apache.xml.serialize package that ships with Xerces.  I do not recall 
whether or not that package prereqs any Xerces specific code. 
Theoretically, we could slice out that code from Xerces and drop it into 
Axis without changing a thing.

- James Snell
     Software Engineer, Emerging Technologies, IBM
     James M Snell/Fresno/IBM -
    "God placed me on the earth to do a certain number of things. Right 
now, I am so far behind, I will never die." - Anon.

Please respond to 
Subject:        Re: Looking to remove dependency on xalan...


> This was always a low prioritity item for me, but it's priority has
> for me.  The problem is that prefix/namespace information seems to be
> dropped.  This poses a potential problem for the Admin service.  In the
> short term, the problem I'm facing is that <bean> registry entries
> currently end up with QNames with null namespaces, and therefore are not
> found downstream...
> I'm looking to reuse DOM2Writer from xml-soap.

Good news: the dependency is gone.
Bad news: the problem is still there.

It appears that SAX, by default, consumes the prefixes for you.  I'm
investigating  This may be
important for Soap Messages (as opposed to RPC) processing.

- Sam Ruby

View raw message