[examplotron] structure from other schemas

From: Jonathan Lang <dataweaver42@yahoo.com>
Date: Wed Jul 09 2003 - 04:37:30 UTC

At present, Examplotron follows RELAX NG's lead and treats all elements
with namespaces as annotations. However, it can't provide a schema for
the following as is:

<root>
  <xhtml:html xmlns:xhtml="http://www.w3.org/2002/06/xhtml2">
    <xhtml:head>
      <xhtml:title>Embedded xhtml document</xhtml:title>
    </xhtml:head>
    <xhtml:body>
      <xhtml:p>Hello, there!</xhtml:p>
    </xhtml:body>
  </xhtml:html>
</root>

It _does_ have the syntax tools to handle the above, by extending the
functionality of @occurs. Just as @occurs can change an element that is
normally part of the document structure into an annotation, it could also
be used to change an element that is normally an annotation into part of
the normal document structure. The schema for the above would then be:

  <x:html xmlns:x="http://www.w3.org/2002/06/xhtml2" eg:occurs=".">
    <x:head>
      <x:title>Embedded xhtml document</x:title>
    </x:head>
    <x:body>
      <x:p>Hello, there!</x:p>
    </x:body>
    <foot/>
  </x:html>

And the RELAX NG Schema would be along the lines of:

  <element name="html" ns="http://www.w3.org/2002/06/xhtml2">
    <element name="head">
      <element name="title">
        <ega:example>Hello, there!</ega:example>
      </element>
    </element>
    <element name="body">
      <element name="p">
        <ega:example>Hello, there!</ega:example>
      </element>
    </element>
    <element name="foot" ns="">
      <empty/>
    </element>
  </element>

=====
Jonathan "Dataweaver" Lang

__________________________________
Do you Yahoo!?
SBC Yahoo! DSL - Now only $29.95 per month!
http://sbc.yahoo.com
Received on Wed Jul 9 06:37:34 2003

This archive was generated by hypermail 2.1.8 : Fri Dec 03 2004 - 14:29:47 UTC