[tei-council] datatypes again: make data.key a URI

Syd Bauman Syd_Bauman at Brown.edu
Tue Nov 8 07:19:59 EST 2005


> <person xml:id="foo">....</person>
> <name key="#foo">Mr Phoo</name>

A quite reasonable desire. But if data.key is declared as xsd:anyURI,
what is the difference between data.key and data.code?

Also, URIs can be a pretty messy way of accessing data, even when it
is available on the web. E.g., the US Library of Congress name
authority records seem to be available on the web. However,

  <name key="000058144">Paul Simon</name>

seems much more robust than

  <name key="http://aleph2.libnet.ac.il/F/MLEYHY17VCMSJLLV4MSBNUPRP2PGRN8L916VGRP7IR4QU8TTXF-23761?func=full-set-set&set_number=055717&set_entry=000001&format=001">Paul
  Simon</name>


> My reason for making this change is that I want to enable people to do 
> things like
> 
> <person xml:id="foo">....</person>
> 
> <name key="#foo">Mr Phoo</name>
> 
> and get some validation. 

BTW, how does one write a simple link-checker for things like this in
Schematron? Anyone know? (You can't use <xsl:key>, I don't think; can
you?) 


> To support additionally your requirement for "key" explicitly to point 
> to something external and non XML we could do one of the following
> 
> -- use another attribute -- but then people have to choose which
>    and we risk ambiguity if one points at one thing and the other 
>    at another

Although we could make the attributes mutually exclusive -- ODD
supports that.


> -- add explicit rules about how a URL is to be constructed from the key 
>    value, either in P5 or in the document instance

I don't understand what you might be getting at, here.


> What I don't know for sure is what in principle it means to say
> <name key="foo"> where foo is defined as a URL -- it's not a
> validation error, so it may be that we can just say that if the
> value is like this it is an application dependent string just like
> the old key thing was.

It means the "rel_path" portion of a URI with value "foo", usually
interpreted by systems to be the file in the same directory with name
"foo".




More information about the tei-council mailing list