SlideShare una empresa de Scribd logo
1 de 3
Descargar para leer sin conexión
XML Schema and RELAX NG
                Element Comparison
                                      Michael Fitzgerald
                                      http://www.overduebooks.net

This document briefly compares XML Schema’s 42 elements with RELAX NG’s 28 elements. In the table
that follows, the first column lists all the XML Schema elements while the second column lists any
RELAX NG elements that have a one-to-one relationship, a comparable purpose, or only a roughly similar
purpose to XML Schema elements. Elements unique to each language are also listed in separate tables
below.

The prefixes in the tables, xs:, rng:, and a:, are associated with the following namespaces:

    •   xs: with http://www.w3.org/2001/XMLSchema
    •   rng: with http://relaxng.org/ns/structure/1.0
    •   a: with http://relaxng.org/ns/compatibility/annotations/1.0

                XML Schema Element                               RELAX NG Element
     xs:all                                        rng:interleave, rng:optional
     xs:annotation                                 a:documentation
     xs:any                                        rng:anyName, rng:nsName
     xs:anyAttribute                               rng:anyName, rng:nsName
     xs:appInfo                                    a:documentation
     xs:attribute                                  rng:attribute
     xs:attributeGroup                             rng:define
     xs:choice                                     rng:choice
     xs:complexContent
     xs:complexType                                rng:element, rng:define, rng:ref
     xs:documentation                              a:documentation
     xs:element                                    rng:element
     xs:enumeration                                rng:choice, rng:value
     xs:extension                                  rng:param
     xs:field
     xs:fractionDigits                             rng:param
     xs:group                                      rng:group, rng:div
     xs:import                                     rng:externalRef, rng:parentRef
     xs:include                                    rng:include, rng:externalRef
     xs:key
     xs:keyref
     xs:length                                     rng:param
     xs:list                                       rng:list

                                                   1
xs:maxExclusive                               rng:param
    xs:maxInclusive                               rng:param
    xs:maxLength                                  rng:param
    xs:minExclusive                               rng:param
    xs:minInclusive                               rng:param
    xs:minLength                                  rng:param
    xs:notation
    xs:pattern                                    rng:param
    xs:redefine                                   rng:include, rng:define
    xs:restriction                                rng:except, rng:notAllowed
    xs:schema                                     rng:grammar
    xs:selector
    xs:sequence
    xs:simpleContent
    xs:simpleType
    xs:totalDigits                                rng:param
    xs:union                                      rng:list
    xs:unique
    xs:whiteSpace                                 rng:param




XML Schema Unique Elements
The following table lists XML Schema elements for which there is no similar or equivalent RELAX NG
element (first column) followed by an explanation why (second column).

         XML Schema Element                              Explanation
        xs:complexContent Not necessary in RELAX NG syntax
        xs:field                 RELAX NG does not implement keys
        xs:key                   RELAX NG does not implement keys
        xs:keyref                RELAX NG does not implement keys
        xs:notation              RELAX NG does not directly support notations
        xs:selector              RELAX NG does not implement keys
        xs:sequence              Not necessary in RELAX NG syntax
        xs:simpleContent         Not necessary in RELAX NG syntax
        xs:simpleType            RELAX NG uses external datatype libraries; types are external
        xs:unique                RELAX NG does not implement keys




                                                  2
RELAX NG Unique Elements
The following tables lists RELAX NG elements for which there is no equivalent or similar XML Schema
element (first column) followed by an explanation why (second column).

         RELAX NG Element                                 Explanation
      rng:data                    Uses the xs:type attribute
      rng:empty                   Uses the xs:complexType element
      rng:interleave              XML Schema requires deterministic content models
      rng:mixed                   Uses with xs:mixed attribute
                                  Achieved with xs:minOccurs="1" and
      rng:oneOrMore
                                  xs:maxOccurs="unbounded"
                                  Achieved with xs:minOccurs="0" and
      rng:optional
                                  xs:maxOccurs="1"
      rng:param                   Uses facet elements (xs:maxLength, xs:minLength, etc.
      rng:ref                     Achieved with the xs:ref attribute
      rng:start                   Uses global xs:element declaration
      rng:text                    Achieved with xs:type="xsd:string" attribute
      rng:value                   Achieved with xs:value attribute
                                  Achieved with xs:minOccurs="0" and
      rng:zeroOrMore
                                  xs:maxOccurs="unbounded"




                                                  3

Más contenido relacionado

Similar a XML Schema and RELAX NG Element Comparison

Similar a XML Schema and RELAX NG Element Comparison (7)

Quick start reg ex
Quick start reg exQuick start reg ex
Quick start reg ex
 
I1
I1I1
I1
 
Parsers Combinators in Scala, Ilya @lambdamix Kliuchnikov
Parsers Combinators in Scala, Ilya @lambdamix KliuchnikovParsers Combinators in Scala, Ilya @lambdamix Kliuchnikov
Parsers Combinators in Scala, Ilya @lambdamix Kliuchnikov
 
Native XML processing in C++ (BoostCon'11)
Native XML processing in C++ (BoostCon'11)Native XML processing in C++ (BoostCon'11)
Native XML processing in C++ (BoostCon'11)
 
Searching for AI - Leveraging Solr for classic Artificial Intelligence tasks
Searching for AI - Leveraging Solr for classic Artificial Intelligence tasksSearching for AI - Leveraging Solr for classic Artificial Intelligence tasks
Searching for AI - Leveraging Solr for classic Artificial Intelligence tasks
 
ArangoDB - Using JavaScript in the database
ArangoDB - Using JavaScript in the databaseArangoDB - Using JavaScript in the database
ArangoDB - Using JavaScript in the database
 
Sperasoft‬ talks j point 2015
Sperasoft‬ talks j point 2015Sperasoft‬ talks j point 2015
Sperasoft‬ talks j point 2015
 

Último

+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
?#DUbAI#??##{{(☎️+971_581248768%)**%*]'#abortion pills for sale in dubai@
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Safe Software
 

Último (20)

AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of Terraform
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
Manulife - Insurer Innovation Award 2024
Manulife - Insurer Innovation Award 2024Manulife - Insurer Innovation Award 2024
Manulife - Insurer Innovation Award 2024
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
 
Top 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live StreamsTop 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live Streams
 

XML Schema and RELAX NG Element Comparison

  • 1. XML Schema and RELAX NG Element Comparison Michael Fitzgerald http://www.overduebooks.net This document briefly compares XML Schema’s 42 elements with RELAX NG’s 28 elements. In the table that follows, the first column lists all the XML Schema elements while the second column lists any RELAX NG elements that have a one-to-one relationship, a comparable purpose, or only a roughly similar purpose to XML Schema elements. Elements unique to each language are also listed in separate tables below. The prefixes in the tables, xs:, rng:, and a:, are associated with the following namespaces: • xs: with http://www.w3.org/2001/XMLSchema • rng: with http://relaxng.org/ns/structure/1.0 • a: with http://relaxng.org/ns/compatibility/annotations/1.0 XML Schema Element RELAX NG Element xs:all rng:interleave, rng:optional xs:annotation a:documentation xs:any rng:anyName, rng:nsName xs:anyAttribute rng:anyName, rng:nsName xs:appInfo a:documentation xs:attribute rng:attribute xs:attributeGroup rng:define xs:choice rng:choice xs:complexContent xs:complexType rng:element, rng:define, rng:ref xs:documentation a:documentation xs:element rng:element xs:enumeration rng:choice, rng:value xs:extension rng:param xs:field xs:fractionDigits rng:param xs:group rng:group, rng:div xs:import rng:externalRef, rng:parentRef xs:include rng:include, rng:externalRef xs:key xs:keyref xs:length rng:param xs:list rng:list 1
  • 2. xs:maxExclusive rng:param xs:maxInclusive rng:param xs:maxLength rng:param xs:minExclusive rng:param xs:minInclusive rng:param xs:minLength rng:param xs:notation xs:pattern rng:param xs:redefine rng:include, rng:define xs:restriction rng:except, rng:notAllowed xs:schema rng:grammar xs:selector xs:sequence xs:simpleContent xs:simpleType xs:totalDigits rng:param xs:union rng:list xs:unique xs:whiteSpace rng:param XML Schema Unique Elements The following table lists XML Schema elements for which there is no similar or equivalent RELAX NG element (first column) followed by an explanation why (second column). XML Schema Element Explanation xs:complexContent Not necessary in RELAX NG syntax xs:field RELAX NG does not implement keys xs:key RELAX NG does not implement keys xs:keyref RELAX NG does not implement keys xs:notation RELAX NG does not directly support notations xs:selector RELAX NG does not implement keys xs:sequence Not necessary in RELAX NG syntax xs:simpleContent Not necessary in RELAX NG syntax xs:simpleType RELAX NG uses external datatype libraries; types are external xs:unique RELAX NG does not implement keys 2
  • 3. RELAX NG Unique Elements The following tables lists RELAX NG elements for which there is no equivalent or similar XML Schema element (first column) followed by an explanation why (second column). RELAX NG Element Explanation rng:data Uses the xs:type attribute rng:empty Uses the xs:complexType element rng:interleave XML Schema requires deterministic content models rng:mixed Uses with xs:mixed attribute Achieved with xs:minOccurs="1" and rng:oneOrMore xs:maxOccurs="unbounded" Achieved with xs:minOccurs="0" and rng:optional xs:maxOccurs="1" rng:param Uses facet elements (xs:maxLength, xs:minLength, etc. rng:ref Achieved with the xs:ref attribute rng:start Uses global xs:element declaration rng:text Achieved with xs:type="xsd:string" attribute rng:value Achieved with xs:value attribute Achieved with xs:minOccurs="0" and rng:zeroOrMore xs:maxOccurs="unbounded" 3