Home > Articles > Programming > Java

Alternatives to XML Schemas

  • Print
  • + Share This
XML Schemas may not be right for every application. In this article, David Gulbransen describes situations in which RELAX NG or Schematron may be a better choice as a schema, or how they could supplement XML Schemas.
This article is adapted from David Gulbransen's book Special Edition Using XML Schema (Que, 2001, ISBN 0-7897-2607-6).
Like this article? We recommend

Like this article? We recommend

XML Schemas are simply one type of schema. There are also database schemas, and even Document Type Definitions (DTDs) are a type of schema. There are also alternative schemas for XML such as RELAX NG and Schematron, which offer the ability to validate XML files, although using slightly different mechanisms that are not based on the W3C Recommendation.

The only official schema recommendation from the W3C is the XML Schemas Part 1 and Part 2. Document Type Definitions are implicit in the details of the XML 1.0 Recommendation. However, the W3C is not the only organization in which information professionals participate; the Organization for the Advancement of Structure Information Standards (OASIS) is another organization that works toward creating standards for developers to follow for applications such as schemas. In fact, OASIS has proposed the RELAX NG standard as an alternative technology to XML Schemas. Similarly, interested individuals such as Rick Jelliffe of the Academia Sinica Computing Centre are creating alternatives such as Schematron.

The Need for Alternatives

The XML Schema Recommendation has been the subject of much debate within the development community. Many developers are happy to have issues such as datatypes addressed, while others have felt that XML Schemas tries to be everything to everyone, and includes too much. Some developers relish the fact that XML Schemas are well-formed XML documents, while others feel that the syntax and structure of XML Schemas are needlessly complicated. These are some of the debates among users who are implementing schemas with their XML documents, and some of those users have turned to alternate methods for describing schemas for XML.

  • + Share This
  • 🔖 Save To Your Account