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

RE: Attribute Uses

From: John Verhaeg <jverhaeg@metamatrix.com>
Date: Mon, 17 Jun 2002 09:07:48 -0500
Message-ID: <C7CDD3E67B05D411A45800E018C1614E7D5E70@mail>
To: "'ht@cogsci.ed.ac.uk'" <ht@cogsci.ed.ac.uk>
Cc: "XML Schema Mailing List (E-mail)" <xmlschema-dev@w3.org>

I think I now understand where my misunderstanding was, based upon Jeni
pointing out that validation rules apply to instance documents, not the
validation of schemas.  However, I'm now a bit confused by your statement
that "...since defaults don't affect validation there's no reason not to
allow a change of default."  In an instance document, there is no facility
to change the default, let alone a reason to allow for it.  Am I missing
something again (I think I'm 0 for 3 so far in my comments about my initial
understanding of the sForS...)?

John P. A. Verhaeg
JVerhaeg@MetaMatrix.Com
MetaMatrix, Inc.
11477 Olde Cabin Road Suite 400
Creve Coeur, MO 63141
(314) 739-3190 x150


-----Original Message-----
From: ht@cogsci.ed.ac.uk [mailto:ht@cogsci.ed.ac.uk]
Sent: Monday, June 17, 2002 5:27 AM
To: John Verhaeg
Cc: XML Schema Mailing List (E-mail)
Subject: Re: Attribute Uses


John Verhaeg <jverhaeg@metamatrix.com> writes:

> The "Attribute Use" described in section 3.2.2 of the Structures spec when
a
> "ref" attribute is present seems to indicate that, if present, the
> default/fixed value must match the value specified in the declaration (the
> globally defined Attribute):

I think you're misreading the text below.

> "value constraint} If there is a default or a fixed [attribute]
> <http://www.w3.org/TR/xml-infoset/>, then a pair consisting of the ·actual
> value· (with respect to the {type definition} of the {attribute
> declaration}) of that [attribute] <http://www.w3.org/TR/xml-infoset/> and
> either default or fixed, as appropriate, otherwise ·absent·."

the 'as appropriate' means as determined by which [attribute] is
present.

> However, item 4 of Validation Rule: Attribute Locally Valid in section
3.2.4
> states:
> 
> "4 The item's ·actual value· must match the value of the {value
constraint},
> if it is present and fixed. "
> 
> This seems to indicate that default values can be overridden in Attribute
> Uses.  XML Spy seems to allow the value to be overridden regardless of
> whether the value constraint is fixed or default.

That's correct, since defaults don't affect validation there's no
reason not to allow a change of default.

> Am I reading this incorrectly?  It seems as if there is both a
documentation
> error in the spec and a problem with Spy.

So I think at best a clarification is needed in the spec. and I
disagree with Spy's allowing a 'fixed' value to be changed.

ht
-- 
  Henry S. Thompson, HCRC Language Technology Group, University of Edinburgh
          W3C Fellow 1999--2002, part-time member of W3C Team
     2 Buccleuch Place, Edinburgh EH8 9LW, SCOTLAND -- (44) 131 650-4440
	    Fax: (44) 131 650-4587, e-mail: ht@cogsci.ed.ac.uk
		     URL: http://www.ltg.ed.ac.uk/~ht/
 [mail really from me _always_ has this .sig -- mail without it is forged
spam]
Received on Monday, 17 June 2002 10:07:51 GMT

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