[XML-DEV Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

RE: ANN: SAX Filters for Namespace Processing

  • From: Michael Brennan <Michael_Brennan@a...>
  • To: xml-dev@l...
  • Date: Tue, 31 Jul 2001 17:03:18 -0700

soap sax
> From: Richard Tobin [mailto:richard@c...]

<snip/>

> The problem with elements goes away if you take the view implied by
> Simon's transformations: that an unqualified child element is
> equivalent (at the application level) to one in the containing
> namespace.  You can then mix elements from different namespaces simply
> by qualifying the element or setting the "default namespace" at a
> boundary between namespaces.
> 
> This interpretation has the disadvantage of not being supported by
> various standard tools; 

It also breaks SOAP. This is probably worth pointing out since SOAP has been
cited as an example of a spec that sanctions the use of unqualified
elements. It would be a violation of SOAP to consider such elements to have
the same namespace as their parent. That is quite explicitly not the intent
of the SOAP spec, and a SAX filter that changes this would break any
compliant SOAP implementation.

I agree with those who argue that the use of unqualified elements is bad
practice. I also think the SOAP spec takes the right approach on this. SOAP
specifies an envelope that can carry other XML documents within it. Any
unqualified elements within a SOAP envelope are part of such a document, NOT
part of the SOAP envelope. If SOAP did not allow this, then SOAP could not
be used to carry XML documents that don't use namespaces. (And given that
there are still plenty of such documents out there, that would be a pretty
draconian restriction.)

All elements defined by the SOAP spec itself MUST be namespace-qualified.
(At least in 1.2. There are some unfortunate ambiguities in 1.1.)

Given this example, I'd say it is terribly dangerous to make the general
assumption that an unqualified child element is equivalent to one in the
containing namespace. You have to know the explicit intent of the author.

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
 

Stylus Studio has published XML-DEV in RSS and ATOM formats, enabling users to easily subcribe to the list from their preferred news reader application.


Stylus Studio Sponsored Links are added links designed to provide related and additional information to the visitors of this website. they were not included by the author in the initial post. To view the content without the Sponsor Links please click here.

Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.