OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: ANN: SAX Filters for Namespace Processing



>Not qualifying child elements is a bad practice; as Tim Bray pointed
>out, it leads to collisions when you start mixing elements from
>different namespaces.
>
>Not qualifying attributes is a neutral practice. It appears to have no
>negative side effects (RDF excepted).

First to point out the obvious: the reason there is a difference
between elements and attributes in this respect is that elements
can be nested, but attributes can't.

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; in particular XSLT will not fix up the
namespace declarations as it does for the standard interpretation.

>Instead of trying to impose a technical solution, better to write the
>author of any schema that uses unqualified child elements an email and
>explain that they are not writing a portable schema. Bad design is a
>human problem and is better solved by humans.

But the use of unqualified child elements (though not Simon's
equivalence) is explicitly supported by XML Schemas - see
elementFormDefault.  It is not universally agreed that this is bad
design.

-- Richard