Re: Valid content model

Dear All,

Thanks to Mark who corrected my complex type (see below).

Anyway, is the following content model valid ? It seems 
unambiguous and the "name-type mapping" constraint is 
respected. is there any other rule that could make it 
invalid ?
 
<xsd:element name="X">
  <xsd:complexType>
   <xsd:sequence>
    <xsd:choice>
        <xsd:element name="A" type="xsd:string"/>
        <xsd:element name="B" type="xsd:string"/>
    </xsd:choice>
    <xsd:element name="C" type="xsd:string"/>
    <xsd:choice>
        <xsd:element name="A" type="xsd:string"/>
        <xsd:element name="B" type="xsd:string"/>
    </xsd:choice>
  </xsd:sequence>
  </xsd:complexType>
 </xsd:element>


Thank you very much.

Best regards,
Claude.


Mark Feblowitz wrote:
> 
> I think you meant
> 
>         <xsd:element name="X">
>                 <xsd:complexType>
>                         <xsd:sequence>
>                                 <xsd:choice>
>                                         <xsd:element name="A"
> type="xsd:string"/>
>                                         <xsd:element name="B"
> type="xsd:string"/>
>                                 </xsd:choice>
>                                 <xsd:element name="C" type="xsd:string"/>
>                                 <xsd:choice>
>                                         <xsd:element name="A"
> type="xsd:string"/>
>                                         <xsd:element name="B"
> type="xsd:string"/>
>                                 </xsd:choice>
>                         </xsd:sequence>
>                 </xsd:complexType>
>         </xsd:element>
> 
> Note the "sequence" to support a sequence of choices. Also not the use of a
> "/" on the closing choice tags.
> 
> ----------------------------------------------------------------------------
> ----
> 
> Mark Feblowitz                                   [t] 617.715.7231
> Frictionless Commerce Incorporated     [f] 617.495.0188
> XML Architect                                     [e]
> mfeblowitz@frictionless.com
> 400 Technology Square, 9th Floor
> Cambridge, MA 02139
> www.frictionless.com
> 
> 
>  -----Original Message-----
> From:   Claude Seyrat [mailto:claude.seyrat@expway.tv]
> Sent:   Thursday, November 15, 2001 10:52 AM
> To:     xmlschema-dev@w3.org
> Subject:        Valid content model
> 
> Dear All,
> 
> is the following content model valid ?
> 
> It is unambiguous and the "name-type" constraint is fulfilled
> is there any other rule that could make it invalid ?
> 
> <xsd:element name="X">
>   <xsd:complexType>
>     <xsd:choice>
>         <xsd:element name="A" type="xsd:string"/>
>         <xsd:element name="B" type="xsd:string"/>
>     <xsd:choice>
>     <xsd:element name="C" type="xsd:string"/>
>     <xsd:choice>
>         <xsd:element name="A" type="xsd:string"/>
>         <xsd:element name="B" type="xsd:string"/>
>     <xsd:choice>
>   </xsd:complexType>
>  </xsd:element>
> 
> Thank you very much.
> 
> Best regards,
> Claude.
> 
> --
> ______________________________________________
> 
> Claude Seyrat
> 
> Expway c/o Acland
> 18 avenue Georges V
> 75008 Paris
> tel: 33 1 56 62 11 06 **new**
> fax: 33 1 56 62 11 11
> mail: claude.seyrat@expway.tv

-- 
______________________________________________

Claude Seyrat

Expway c/o Acland
18 avenue Georges V
75008 Paris
tel: 33 1 56 62 11 06 **new**
fax: 33 1 56 62 11 11
mail: claude.seyrat@expway.tv

Received on Thursday, 15 November 2001 11:34:58 UTC