W3C home > Mailing lists > Public > xmlschema-dev@w3.org > April 2002

Re: Attribute Fixed and Prohibited

From: Jeni Tennison <jeni@jenitennison.com>
Date: Mon, 1 Apr 2002 17:29:32 +0100
Message-ID: <1845414876.20020401172932@jenitennison.com>
To: Stanley Guan <stanley.guan@oracle.com>
CC: xmlschema-dev@w3.org
Hi Stanley,

> Is the following a valid attribute declaration?
>   <xs:attribute name="domain" type="xs:positiveInteger" use="prohibited"
>    fixed="123"/>
> If not, where does it state that in the spec.?

From what I can tell, I think that it's a valid *local* attribute
declaration (it's not a valid global attribute declaration, because
you can't have a use attribute on a global attribute declaration).
However, because it doesn't actually correspond to any component, the
type and fixed attributes aren't doing anything, and it's exactly the
same as:

  <xs:attribute name="domain" use="prohibited" />

I don't know why there isn't a constraint that bans attributes aside
from ref and name when use equals prohibited, but there doesn't seem
to be.

Cheers,

Jeni

---
Jeni Tennison
http://www.jenitennison.com/
Received on Monday, 1 April 2002 11:29:33 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 11 January 2011 00:14:30 GMT