W3C home > Mailing lists > Public > public-qt-comments@w3.org > April 2007

[Bug 4487] [XDM] Missing constraint for attribute names

From: <bugzilla@wiggum.w3.org>
Date: Fri, 27 Apr 2007 10:22:55 +0000
To: public-qt-comments@w3.org
Message-Id: <E1HhNbL-0005rk-5g@wiggum.w3.org>


------- Comment #2 from mike@saxonica.com  2007-04-27 10:22 -------
Namespace fixup is not the responsibility of the serializer: the XDM model
contains the tree structure *after* fixup has been applied. This enables anyone
accessing an XDM tree to be confident that it will satisfy basic XML rules such
as names being valid, and no element having two attributes with the same name.
The rule that an attribute in a namespace always has a prefix falls into the
same category.

>In both cases the XDM
shouldn't care, because the prefix is irrelevant to the actual name of the
attribute (the namespace URI/local name pair).

The name of the attribute is not a namespace URI/local name pair: it is a
triple that also includes a prefix: see section 3.3.3 ("In this Data Model,
therefore, the value space for qualified names contains a local-name, an
optional namespace URI, and an optional prefix.")

The prefix is ignored when comparing two names, but it is visible to
applications via functions such as name(). It's important from a usability
perspective that name() applied to a node should return the same string that
you see when serializing the node, since it is often used in messages and
similar output.
Received on Friday, 27 April 2007 10:22:57 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 7 January 2015 15:45:33 UTC