W3C home > Mailing lists > Public > xmlschema-dev@w3.org > July 2004

Extending attributeGroups: self-reference?

From: Hirtle, David <David.Hirtle@nrc-cnrc.gc.ca>
Date: Wed, 7 Jul 2004 11:10:33 -0400
Message-ID: <10C94843061E094A98C02EB77CFC32870A1E2E73@nrcmrdex1d.imsb.nrc.ca>
To: "'xmlschema-dev@w3.org'" <xmlschema-dev@w3.org>

My interpretation of the following lines from the spec [1] is that a
self-reference is necessary when extending an attributeGroup via redefine
(as with other groups):

7.1 If it has an <attributeGroup> among its contents the ·actual value· of
whose ref [attribute] is the same as the ·actual value· of its own name
attribute plus target namespace, then it must have exactly one such group.

For example, this would be correct:

<xs:attributeGroup name="rel.attlist">
	<xs:attributeGroup ref="rel.attlist"/>
	<xs:attributeGroup ref="href.attrib"/>
</xs:attributeGroup>

However, XSV also seems to accept attributeGroup extensions without such a
self-reference (somehow still distinguishing between restriction and
extension, apparently):

<xs:attributeGroup name="rel.attlist">
	<xs:attributeGroup ref="href.attrib"/>
</xs:attributeGroup>

Other validators I've found require the self-reference.  Which is correct?

(Related questions have been asked on this list before, but I didn't find
anything which explicitly answered my question.  Apologies if I'm being
redundant.)

Thanks.

David

[1] http://www.w3.org/TR/xmlschema-1/#src-redefine
Received on Wednesday, 7 July 2004 11:10:34 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 5 February 2014 07:15:10 UTC