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

Re: all group

From: Herve Verjus <herve.verjus@esia.univ-savoie.fr>
Date: Mon, 30 Dec 2002 14:45:50 +0100 (Romance Standard Time)
To: Avin Patel <vze49rz3@verizon.net>
cc: xmlschema <xmlschema-dev@w3.org>
Message-ID: <Pine.WNT.4.51.0212301439180.2688@verjus>


Hi,

On Mon, 30 Dec 2002, Henry S. Thompson wrote:

>
> "Avin Patel" <vze49rz3@verizon.net> writes:
>
> > Hi All,
> > I want to use all group in all group. As I know all group can't have one of
> > the following:
> > 1)can't contain other group
> > 2)can't be contained in other group
> > 3)must be at top level of complex type
> > 4)can't occur multiple time

eumH. Where did you find these constraints ????? I defined an XML Schema
where 1) 2) and 4) are violated and the schema was validated (????)

What and where is the truth ?????

Herve

> >
> > But I can always use all group in all group as following definition, is it
> > correct:
> >
> > <xsd:complexType name="Type1">
> >    <xsd:all>
> >       <xsd:element name="elem1" type="xsd:integer"/>
> >       <xsd:element name="elem2" type="Type2"/>
> >   </xsd:all>
> > </complexType>
> >
> > <xsd:complexType name="Type2">
> >   <xsd:all>
> >        <xsd:element name="elem1" type="xsd:integer"/>
> >        <xsd:element name="elem2" type="xsd:boolean"/>
> >   </xsd:all>
> > </complexType>
>
> Sure, but the result will be to allow
>
>  <elem1>3</elem1>
>  <elem2><elem1>4</elem1>
>         <elem2>true</elem2>
>  </elem2>
>
> etc., which may not be what you wanted.
>
> 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]
>
>

PS: for Outlook users and attached files:
    (my attached files are not directly visible - I don't know why ?).
    Try to use the File menu, then "Save Attachments".

-- Herve VERJUS -------ooOoo------- herve.verjus@esia.univ-savoie.fr --
-- LISTIC-ESIA (Lab.)               Universite de Savoie
-- B.P. 806                         Tel : +33 (0) 450 096 594
-- F - 74016 ANNECY Cedex           Fax : +33 (0) 450 096 590
Received on Monday, 30 December 2002 08:45:45 GMT

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