W3C home > Mailing lists > Public > www-xml-schema-comments@w3.org > April to June 2000

Question on "ref" attribute

From: <gmacri@libero.it>
Date: Sun, 14 May 2000 16:11:28 +0200
To: www-xml-schema-comments@w3.org
Message-Id: <FUJZF4$IIm8BAr5SA29jIKsQocVFt6PoBeRD9uArN_UjgEYTlmc7@libero.it>
When I write a XML schema as this that follow:

<schema xmlns="http://www.w3.org/1999/XMLSchema"
        targetNamespace="http://www.somewhere.org/BookCatalogue"
        xmlns:cat="http://www.somewhere.org/BookCatalogue">
    <element name="BookCatalogue">
        <type>
             <element name="Book" minOccurs="0" maxOccurs="*">
                  <type>
                      <group ref="BookElements"/>
                      <attribute name="Category" minOccurs="1">
                          <datatype source="string">
                              <enumeration value="autobiography"/>
                              <enumeration value="non-fiction"/>
                              <enumeration value="fiction"/>
                          </datatype>
                      </attribute> 
                      <attribute name="InStock" type="boolean" 
default="false"/>
                      <attribute name="Reviewer" type="string" 
default=""/>
                  </type>
             </element>
        </type>
    </element>
    <group name="BookElements" order="seq">
        <element name="Title" type="string"/>
        <element name="Author" type="string"/>
        <element name="Date" type="string"/>
        <element name="ISBN" type="string"/>
        <element name="Publisher" type="string"/>
    </group>
</schema>


the group's "ref" attribute must always refer to a group that is 
child (top level) of schema ?
Received on Sunday, 14 May 2000 10:12:06 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 7 January 2015 14:49:52 UTC