OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

relax-ng message

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [Elist Home]


Subject: Datatypes variation #1


Here's a possible variation of my datatypes proposal.

1. Get rid of the "datatypeNamespace" attribute

2.  The renaming of the "ns" attribute becomes unnecessary (though it might
be good to rename it to "namespace" anyway).

3. The type attribute is a QName (as it is currently). It always refers to
system-defined namespaces not user-defined namespaces.

4. An unprefixed value of the type attribute would prefer to the TREX built
in namespaces (string and normalizedString).

5.  The <ref> element would be used as a datatypeSpec to refer to
user-defined datatypes.

So for example if you defined a datatype as follows:

<datatype name="localTime">
  <setParams type="xsd:time">
    <param name="pattern">[0-9]+:[0-9]+:[0-9]+</param>
  </setParams>
</datatype>

Then you would reference it as:

<element name="appointment">
   <data>
      <ref name="localTime"/>
   </data>
</element>

To use it to derive a new datatype you would do:

<datatype name="officeHours">
  <setParams>
     <ref name="localTime"/>
     <param name="minInclusive">08:00:00</param>
     <param name="maxInclusive">20:00:00</param>
  </setParams>
</datatype>

James








[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [Elist Home]


Powered by eList eXpress LLC