A Simple Document W3C XML Schema

This schema defines the urn:publicid:-:Norman+Walsh:Schema Example:EN namespace by defining several elements and their complex types.

Documents that conform to this schema have the general form:

<doc xmlns="urn:publicid:-:Norman+Walsh:Schema Example:EN">
  <title>Sample Document</title>
  <para>Some paragraphs.</para>
</doc>

The Types

This schema only defines three element types: doc, title, and para.

The doc Type

This is a document.

The title Type

This is a title.

The para Type

This is a paragraph.

The role Attribute

Each of the complex types in this schema allows an optional role attribute. The role attribute is simply a string.

The Elements

This schema defines one element of each complex type.

The Schema

The schema wrapper surrounds all these definitions.