W3C home > Mailing lists > Public > www-xml-schema-comments@w3.org > October to December 2001

Primer description 4.4 Deriving Complex Types by Restriction

From: David Brown (WEBDATA) <davebrow@microsoft.com>
Date: Mon, 26 Nov 2001 11:46:03 -0800
Message-ID: <81EDEEE0355CB24380319632393FD56D01661E67@red-msg-01.redmond.corp.microsoft.com>
To: <xmlschema-dev@w3.org>, <www-xml-schema-comments@w3.org>
> The primer has an example of deriving a complex type, "ConfirmedItems", from an existing complex type, "ipo:Items".
> 
> The base complex type has an element defined locally with a locally defined type.
> 
> The derived type is attempting to restrict the occurance of the base's locally defined element.
> 
> There is a note in the Structures Spec, Schema Component Constraint: Particle Restriction OK (Elt:Elt -- NameAndTypeOK), stating
> NOTE: The above constraint on {type definition} <\l >  means that in deriving a type by restriction, any contained type definitions must themselves be explicitly derived by restriction from the corresponding type definitions in the base definition. 
> The not seems to say that the type associated with the elements must also be derived from the base, yet the Primer's example is working with only locally defined types.
> 
> Question1: Is the Primer example in 4.4 a valid representation of a restriction?
> Question2: For the purposes of derivation, are two local elements with locally defined types supposed to be treated as identical or should the element be defined globally and then referred to?
> 
> Thanks,
>                                                             
> Dave Brown
> *	Software Design Engineer/Test
> *	davebrow@microsoft.com
> *	(425) 705 - 0804
> 
> 
Received on Monday, 26 November 2001 14:47:09 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Sunday, 6 December 2009 18:12:57 GMT