- From: Martin Gudgin <marting@develop.com>
- Date: Sun, 21 May 2000 08:03:09 -0400
- To: <Daniel.Veillard@w3.org>
- Cc: "Schema Comments" <www-xml-schema-comments@w3.org>
----- Original Message ----- From: "Daniel Veillard" <Daniel.Veillard@w3.org> To: "Martin Gudgin" <marting@develop.com> Cc: <Daniel.Veillard@w3.org> Sent: Friday, May 19, 2000 8:54 AM Subject: Re: Attribute remapping support in XML Schemas > On Fri, May 19, 2000 at 08:22:28AM -0400, Martin Gudgin wrote: > > The way I read the namespace rec unprefixed attributes are *always* locally > > scoped by their containing element. The only way to have a global attribute > > is to give it a prefix. So assuming a namespace decl for prefix x1; > > > > <x1:foo bar='somevalue' x1:bar='somevalue'/> > > <x1:quux bar='somevalue' x1:bar='somevalue'/> > > > > x1:bar is the same attribute in both cases, has the same meaning etc etc. > > Ok section 5.2 with default namespace, i.e. if foo has no no x1 prefix: > > "Note that default namespaces do not apply directly to attributes." > > <doc xmlns='somvalue'><foo bar="somevalue"/></doc> > > The spec says "bar is not in "somvalue" namespace. > I should have been more clear that it was just for default namespace. [MJG] Hmmm. I didn't read the namespace rec that way. I saw bar as being locally scoped by foo. I think the phrase you are refering too is just trying to state that unprefixed attributes are never global even if there is a default namespace. The way I read it the following two instance documents are identical at the infoset level; <root xmlns:x1='urn:mjg-x1'> <x1:foo bar='somevalue' x1:bar='somevalue'/> <x1:quux bar='somevalue' x1:bar='somevalue'/> </root> <root xmlns='urn:mjg-x1' xmlns:x1='urn:mjg-x1'> <foo bar='somevalue' x1:bar='somevalue'/> <quux bar='somevalue' x1:bar='somevalue'/> </root> In both documents the unprefixed bar attributes are locally scoped whereas the prefixed bar attributes are global. Martin Gudgin DevelopMentor
Received on Monday, 22 May 2000 03:34:56 UTC