W3C home > Mailing lists > Public > xmlschema-dev@w3.org > May 2001

"default" and "ref" with attributes

From: Gesmann, Dr., Michael <Michael.Gesmann@softwareag.com>
Date: Fri, 4 May 2001 13:28:20 +0200
Message-ID: <2B1792E820ACD411AD5A00508BF9A3FC01FFAFDB@daemsg03.software-ag.de>
To: "'xmlschema-dev@w3.org'" <xmlschema-dev@w3.org>
I'm trying to understand the meaning of "default" and "fixed" when defining

This is, what I hope is correct:
Attribute declarations can define "default" or "fixed" values, independent
of whether it is a global (parent is schema) or a local (parent is not
schema) declaration. In particular, this is also possible for referencing
attribute declarations i.e. the "ref" attribute is present (src-attribute).
If referencing and global attribute declaration have a value constraint and
one describes as fixed value, the other value constraint must also describe
the same fixed value (au-props-correct.2). 

Now my question:
What is the correct semantics if global and local "default" values are
E.g. <xs:attribute name="myAttr" default="myValue1" .../> 
and in some other place: <xs:attribute ref="myAttr" default="anotherValue"
... >
(Is this described in the XML-Schema Rec., if yes where?)

While trying to understand this and comparing "default" and "fixed" between
attribute and element declarations, another question came up:
Why does XML-Schema allow for definition of "default" and "fixed" values in
referencing attribute declarations but not in referencing element

Regards and many thanks for help

Received on Friday, 4 May 2001 07:28:38 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 7 January 2015 14:55:51 UTC