xml-xmlbeans-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Eric Vasilik" <eric...@bea.com>
Subject RE: v2 XMLStreamReader namespace issue
Date Fri, 13 Feb 2004 06:30:09 GMT
The current implementation of XMLStreamReader does not attempt to "fix
up" the XML to reflect a well formed document.  It is designed to be
very fast and require low overhead.

You say that "...prefixes and namespaces default to null for all
elements."  As far as I know, prefixes are preserved for elements, but
there is a bug for attributes where prefixes are not preserved.  And,
elements and prefixes should also have the proper namespace reflected.
Could you be more specific about this statement?

The prefix tracking thread is a different issue.  It is about the lack
of prefix support in v1.

The feature I think you are looking for is a XMLStreamReader with save
semantics (available via an option, perhaps).  Getting the saver working
with the new store is a high priority for me.  I have considered a
version of XMLStreamReader which uses it.  This should give you what I
think you are asking for: namespace attributes will be made available
through the XMLStreamReader to reflect more well formed, "correct" XML

- Eric

-----Original Message-----
From: David Waite [mailto:mass@akuma.org] 
Sent: Thursday, February 12, 2004 9:46 PM
To: xmlbeans-dev@xml.apache.org
Subject: v2 XMLStreamReader namespace issue

One issue I have encountered using the XMLStreamReader support in v2 is 
that namespaces are not created in the process, so prefixes and 
namespaces default to null for all elements.

  My current test is rather simple, it creates an XMLEventWriter, 
creates an XMLStreamReader off of an XMLObject and wraps that up in an 
XMLEventReader, and calls writer.add , passing in the event reader. The 
StAX implementation used is the 0.7 reference implementation by BEA. 
With the change from before it appears that the document now finishes 
output, but without any namespaces.

Is there any workaround for this effect I can do in my code? This seems 
related to the recent "YAP - Prefix Tracking" thread.

-David Waite

- ---------------------------------------------------------------------
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/

View raw message