← Prev in month ← Prev in thread

Side-by-side comparison of XML Schema and Relax NG

From
Costello, Roger L. <>
To
"" <>
Date
2012-02-24T16:30:59Z
ID
<>
Thread
Side-by-side comparison of XML Schema and Relax NG
Hi Folks,

Below are two implementations of this data model:

     The content of a Book element is one or more 
     Title elements.  The content of each Title element 
     is text/string.

The data model is first implemented using this XML markup language: XML Schema.

Next, the data model is implemented using this XML markup language: Relax NG.

----------------
XML Schema
----------------
<schema xmlns="http://www.w3.org/2001/XMLSchema">
    <element name="Book">
        <complexType>
            <sequence>
                <element name="Title" maxOccurs="unbounded" type="string" />
            </sequence>
        </complexType>
    </element>
</schema>

-----------
Relax NG
-----------
<element name="Book" 
                    xmlns="http://relaxng.org/ns/structure/1.0">
    <oneOrMore>
        <element name="Title"><text/></element>
    </oneOrMore>
</element>

Do you have other examples of side-by-side comparisons of XSD and RNG?

/Roger
← Prev in month ← Prev in thread