ONYX - 9.0 - Utilisation - Designer XML Schema Definition (XSD)

Différence entre versions

De MappingDoc
Ligne 3 : Ligne 3 :
 
<!-- edited with XMLSpy v2008 rel. 2 sp2 (http://www.altova.com) by SHOCK (SHOCK) -->
 
<!-- edited with XMLSpy v2008 rel. 2 sp2 (http://www.altova.com) by SHOCK (SHOCK) -->
 
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified" attributeFormDefault="unqualified">
 
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified" attributeFormDefault="unqualified">
<xs:element name="doc">
+
    <xs:element name="doc">
<xs:annotation>
+
        <xs:annotation>
<xs:documentation>ROOT element with no other semantic</xs:documentation>
+
            <xs:documentation>ROOT element with no other semantic</xs:documentation>
</xs:annotation>
+
        </xs:annotation>
              <xs:complexType>
+
        <xs:complexType>
<xs:sequence>
+
            <xs:sequence>
                        <xs:element name="page" minOccurs="0" maxOccurs="unbounded">
+
                <xs:element name="page" minOccurs="0" maxOccurs="unbounded">
<xs:annotation>
+
                    <xs:annotation>
<xs:documentation>Represents a document or a single page in a document. The order between 'group' and 'field' child elements doesn't matter, but the order between 'group' elements of same name requires special attention </xs:documentation>
+
                        <xs:documentation>Represents a document or a single page in a document. The order between 'group' and 'field' child elements doesn't matter, but the order between 'group' elements of same name requires special attention </xs:documentation>
</xs:annotation>
+
                    </xs:annotation>
<xs:complexType>
+
                    <xs:complexType>
<xs:choice maxOccurs="unbounded">
+
                        <xs:choice maxOccurs="unbounded">
<xs:element name="field" minOccurs="0" maxOccurs="unbounded">
+
                            <xs:element name="field" minOccurs="0" maxOccurs="unbounded">
<xs:annotation>
+
                                <xs:annotation>
<xs:documentation>Represents a simple field (a kind of attribute) for the whole page.</xs:documentation>
+
                                    <xs:documentation>Represents a simple field (a kind of attribute) for the whole page.</xs:documentation>
</xs:annotation>
+
                                </xs:annotation>
<xs:complexType>
+
                                <xs:complexType>
<xs:simpleContent>
+
                                    <xs:simpleContent>
<xs:extension base="nonEmptyString">
+
                                        <xs:extension base="nonEmptyString">
<xs:attribute name="name" type="nonEmptyString" use="required">
+
                                            <xs:attribute name="name" type="nonEmptyString" use="required">
<xs:annotation>
+
                                                <xs:annotation>
<xs:documentation>Required to identify different types of 'field'. Value must be unique at this level (preceding and following sibling)</xs:documentation>
+
                                                    <xs:documentation>Required to identify different types of 'field'. Value must be unique at this level (preceding and following sibling)</xs:documentation>
</xs:annotation>
+
                                                </xs:annotation>
</xs:attribute>
+
                                            </xs:attribute>
</xs:extension>
+
                                        </xs:extension>
</xs:simpleContent>
+
                                    </xs:simpleContent>
</xs:complexType>
+
                                </xs:complexType>
</xs:element>
+
                            </xs:element>
<xs:element name="group" minOccurs="0" maxOccurs="unbounded">
+
                            <xs:element name="group" minOccurs="0" maxOccurs="unbounded">
<xs:annotation>
+
                                <xs:annotation>
<xs:documentation>A 'group' is a collection of lines and offers a convenient way to create tables</xs:documentation>
+
                                    <xs:documentation>A 'group' is a collection of lines and offers a convenient way to create tables</xs:documentation>
</xs:annotation>
+
                                </xs:annotation>
<xs:complexType>
+
                                <xs:complexType>
<xs:sequence>
+
                                    <xs:sequence>
<xs:element name="line" minOccurs="0" maxOccurs="unbounded">
+
                                        <xs:element name="line" minOccurs="0" maxOccurs="unbounded">
<xs:annotation>
+
                                            <xs:annotation>
<xs:documentation>Represents a row in a table</xs:documentation>
+
                                                <xs:documentation>Represents a row in a table</xs:documentation>
</xs:annotation>
+
                                            </xs:annotation>
<xs:complexType>
+
                                            <xs:complexType>
<xs:sequence>
+
                                                <xs:sequence>
<xs:element name="field" minOccurs="0" maxOccurs="unbounded">
+
                                                    <xs:element name="field" minOccurs="0" maxOccurs="unbounded">
<xs:annotation>
+
                                                        <xs:annotation>
<xs:documentation>Represents a field in a row</xs:documentation>
+
                                                            <xs:documentation>Represents a field in a row</xs:documentation>
</xs:annotation>
+
                                                        </xs:annotation>
<xs:complexType>
+
                                                        <xs:complexType>
<xs:simpleContent>
+
                                                            <xs:simpleContent>
<xs:extension base="nonEmptyString">
+
                                                                <xs:extension base="nonEmptyString">
<xs:attribute name="name" type="nonEmptyString" use="required">
+
                                                                    <xs:attribute name="name" type="nonEmptyString" use="required">
<xs:annotation>
+
                                                                        <xs:annotation>
<xs:documentation>Required to identify different types of 'field' in a line. Value must be unique at this level (preceding and following sibling)</xs:documentation>
+
                                                                            <xs:documentation>Required to identify different types of 'field' in a line. Value must be unique at this level (preceding and following sibling)</xs:documentation>
</xs:annotation>
+
                                                                        </xs:annotation>
</xs:attribute>
+
                                                                    </xs:attribute>
</xs:extension>
+
                                                                </xs:extension>
</xs:simpleContent>
+
                                                            </xs:simpleContent>
</xs:complexType>
+
                                                        </xs:complexType>
</xs:element>
+
                                                    </xs:element>
</xs:sequence>
+
                                                </xs:sequence>
<xs:attribute name="name" type="nonEmptyString" use="required">
+
                                                <xs:attribute name="name" type="nonEmptyString" use="required">
<xs:annotation>
+
                                                    <xs:annotation>
<xs:documentation>Intended to identify different types of 'line' in a given group</xs:documentation>
+
                                                        <xs:documentation>Intended to identify different types of 'line' in a given group</xs:documentation>
</xs:annotation>
+
                                                    </xs:annotation>
</xs:attribute>
+
                                                </xs:attribute>
</xs:complexType>
+
                                            </xs:complexType>
<xs:unique name="UniqueLineFieldName">
+
                                            <xs:unique name="UniqueLineFieldName">
<xs:annotation>
+
                                                <xs:annotation>
<xs:documentation>group/line/field/@name uniqueness</xs:documentation>
+
                                                    <xs:documentation>group/line/field/@name uniqueness</xs:documentation>
</xs:annotation>
+
                                                </xs:annotation>
<xs:selector xpath="./field"/>
+
                                                <xs:selector xpath="./field"/>
<xs:field xpath="@name"/>
+
                                                <xs:field xpath="@name"/>
</xs:unique>
+
                                            </xs:unique>
</xs:element>
+
                                        </xs:element>
</xs:sequence>
+
                                    </xs:sequence>
<xs:attribute name="name" use="required">
+
                                    <xs:attribute name="name" use="required">
<xs:annotation>
+
                                        <xs:annotation>
<xs:documentation>Intended to identify different types of 'group' in a given 'page'</xs:documentation>
+
                                            <xs:documentation>Intended to identify different types of 'group' in a given 'page'</xs:documentation>
</xs:annotation>
+
                                        </xs:annotation>
<xs:simpleType>
+
                                        <xs:simpleType>
<xs:restriction base="xs:string">
+
                                            <xs:restriction base="xs:string">
                                      <xs:minLength value="1"/>
+
                                                <xs:minLength value="1"/>
                                      <xs:maxLength value="10"/>
+
                                                <xs:maxLength value="10"/>
                                   
+
                                            </xs:restriction>
                                  </xs:restriction>
+
                                        </xs:simpleType>
                                  </xs:simpleType>
+
                                    </xs:attribute>
</xs:attribute>
+
                                </xs:complexType>
</xs:complexType>
+
                            </xs:element>
</xs:element>
+
                        </xs:choice>
</xs:choice>
+
                        <xs:attribute name="name" type="nonEmptyString" use="required">
<xs:attribute name="name" type="nonEmptyString" use="required">
+
                            <xs:annotation>
<xs:annotation>
+
                                <xs:documentation>Intended to identify different types of 'page' in the overall document</xs:documentation>
<xs:documentation>Intended to identify different types of 'page' in the overall document</xs:documentation>
+
                            </xs:annotation>
</xs:annotation>
+
                        </xs:attribute>
</xs:attribute>
+
                    </xs:complexType>
</xs:complexType>
+
                    <xs:unique name="UniqueFieldName">
<xs:unique name="UniqueFieldName">
+
                        <xs:annotation>
<xs:annotation>
+
                            <xs:documentation>/doc/page/field/@name uniqueness</xs:documentation>
<xs:documentation>/doc/page/field/@name uniqueness</xs:documentation>
+
                        </xs:annotation>
</xs:annotation>
+
                        <xs:selector xpath="./field"/>
<xs:selector xpath="./field"/>
+
                        <xs:field xpath="@name"/>
<xs:field xpath="@name"/>
+
                    </xs:unique>
</xs:unique>
+
                </xs:element>
</xs:element>
+
            </xs:sequence>
</xs:sequence>
+
        </xs:complexType>
</xs:complexType>
+
    </xs:element>
</xs:element>
+
    <xs:simpleType name="nonEmptyString">
<xs:simpleType name="nonEmptyString">
+
        <xs:restriction base="xs:string">
<xs:restriction base="xs:string">
+
            <xs:minLength value="1"/>
<xs:minLength value="1"/>
+
        </xs:restriction>
</xs:restriction>
+
    </xs:simpleType>
</xs:simpleType>
 
 
</xs:schema>
 
</xs:schema>
  
 
</syntaxhighlight><br />
 
</syntaxhighlight><br />

Version du 29 novembre 2019 à 10:50

<?xml version="1.0" encoding="UTF-8"?>
<!-- edited with XMLSpy v2008 rel. 2 sp2 (http://www.altova.com) by SHOCK (SHOCK) -->
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified" attributeFormDefault="unqualified">
    <xs:element name="doc">
        <xs:annotation>
            <xs:documentation>ROOT element with no other semantic</xs:documentation>
        </xs:annotation>
        <xs:complexType>
            <xs:sequence>
                <xs:element name="page" minOccurs="0" maxOccurs="unbounded">
                    <xs:annotation>
                        <xs:documentation>Represents a document or a single page in a document. The order between 'group' and 'field' child elements doesn't matter, but the order between 'group' elements of same name requires special attention </xs:documentation>
                    </xs:annotation>
                    <xs:complexType>
                        <xs:choice maxOccurs="unbounded">
                            <xs:element name="field" minOccurs="0" maxOccurs="unbounded">
                                <xs:annotation>
                                    <xs:documentation>Represents a simple field (a kind of attribute) for the whole page.</xs:documentation>
                                </xs:annotation>
                                <xs:complexType>
                                    <xs:simpleContent>
                                        <xs:extension base="nonEmptyString">
                                            <xs:attribute name="name" type="nonEmptyString" use="required">
                                                <xs:annotation>
                                                    <xs:documentation>Required to identify different types of 'field'. Value must be unique at this level (preceding and following sibling)</xs:documentation>
                                                </xs:annotation>
                                            </xs:attribute>
                                        </xs:extension>
                                    </xs:simpleContent>
                                </xs:complexType>
                            </xs:element>
                            <xs:element name="group" minOccurs="0" maxOccurs="unbounded">
                                <xs:annotation>
                                    <xs:documentation>A 'group' is a collection of lines and offers a convenient way to create tables</xs:documentation>
                                </xs:annotation>
                                <xs:complexType>
                                    <xs:sequence>
                                        <xs:element name="line" minOccurs="0" maxOccurs="unbounded">
                                            <xs:annotation>
                                                <xs:documentation>Represents a row in a table</xs:documentation>
                                            </xs:annotation>
                                            <xs:complexType>
                                                <xs:sequence>
                                                    <xs:element name="field" minOccurs="0" maxOccurs="unbounded">
                                                        <xs:annotation>
                                                            <xs:documentation>Represents a field in a row</xs:documentation>
                                                        </xs:annotation>
                                                        <xs:complexType>
                                                            <xs:simpleContent>
                                                                <xs:extension base="nonEmptyString">
                                                                    <xs:attribute name="name" type="nonEmptyString" use="required">
                                                                        <xs:annotation>
                                                                            <xs:documentation>Required to identify different types of 'field' in a line. Value must be unique at this level (preceding and following sibling)</xs:documentation>
                                                                        </xs:annotation>
                                                                    </xs:attribute>
                                                                </xs:extension>
                                                            </xs:simpleContent>
                                                        </xs:complexType>
                                                    </xs:element>
                                                </xs:sequence>
                                                <xs:attribute name="name" type="nonEmptyString" use="required">
                                                    <xs:annotation>
                                                        <xs:documentation>Intended to identify different types of 'line' in a given group</xs:documentation>
                                                    </xs:annotation>
                                                </xs:attribute>
                                            </xs:complexType>
                                            <xs:unique name="UniqueLineFieldName">
                                                <xs:annotation>
                                                    <xs:documentation>group/line/field/@name uniqueness</xs:documentation>
                                                </xs:annotation>
                                                <xs:selector xpath="./field"/>
                                                <xs:field xpath="@name"/>
                                            </xs:unique>
                                        </xs:element>
                                    </xs:sequence>
                                    <xs:attribute name="name" use="required">
                                        <xs:annotation>
                                            <xs:documentation>Intended to identify different types of 'group' in a given 'page'</xs:documentation>
                                        </xs:annotation>
                                        <xs:simpleType>
                                            <xs:restriction base="xs:string">
                                                <xs:minLength value="1"/>
                                                <xs:maxLength value="10"/>
                                            </xs:restriction>
                                        </xs:simpleType>
                                    </xs:attribute>
                                </xs:complexType>
                            </xs:element>
                        </xs:choice>
                        <xs:attribute name="name" type="nonEmptyString" use="required">
                            <xs:annotation>
                                <xs:documentation>Intended to identify different types of 'page' in the overall document</xs:documentation>
                            </xs:annotation>
                        </xs:attribute>
                    </xs:complexType>
                    <xs:unique name="UniqueFieldName">
                        <xs:annotation>
                            <xs:documentation>/doc/page/field/@name uniqueness</xs:documentation>
                        </xs:annotation>
                        <xs:selector xpath="./field"/>
                        <xs:field xpath="@name"/>
                    </xs:unique>
                </xs:element>
            </xs:sequence>
        </xs:complexType>
    </xs:element>
    <xs:simpleType name="nonEmptyString">
        <xs:restriction base="xs:string">
            <xs:minLength value="1"/>
        </xs:restriction>
    </xs:simpleType>
</xs:schema>