Purposes

Natures are not unique. An XML application in a single namespace may have several schemas, even in one schema language. It may have more than one DTD. (XHTML 1.0 has three.) The schema or DTD may be broken up into many modules. Stylesheets, software, documentation, and other related resources may be even more diverse. The specific kinds of resources that are related to a namespace can be further subdivided by purpose. A URI identifying the purpose is included in the rddl:resource element's xlink:arcrole attribute. For example, here are three different rddl:resource elements describing different resources related to MBSML.

 <rddl:resource xlink:type="simple"    xlink:href="http://developer.megabank.com/xml/spec.html"    xlink:role="http://www.w3.org/TR/html4/"    xlink:arcrole      ="http://www.rddl.org/purposes#normative-reference" >   <p>   The   <a href="http://developer.megabank.com/xml/spec.html">MegaBank   Statement Markup Language Specification 1.0</a>   </p> </rddl:resource> <rddl:resource xlink:type="simple"    xlink:href="http://developer.megabank.com/xml/tutorial.html"    xlink:role="http://www.w3.org/TR/html4/"    xlink:arcrole      ="http://www.rddl.org/purposes#non-normative-reference" >   <p>     Alan Williams has written a nice     <a href="http://developer.megabank.com/xml/tutorial.html">     tutorial</a> describing the MegaBank Statement Markup     Language.   </p> </rddl:resource> <rddl:resource xlink:type="simple"    xlink:href      ="http://developer.megabank.com/xml/canonicalization.html"    xlink:role="http://www.w3.org/TR/html4/"    xlink:arcrole="http://www.rddl.org/purposes#canonicalization" >   <p>     Before comparing documents, it is necessary to     <a href=     "http://developer.megabank.com/xml/canonicalization.html">     canonicalize</a> them.   </p> </rddl:resource> 

All three resources have the same nature (HTML 4.0 document). However, they have different purposes. The first refers to the normative specification of MBSML. The second refers to a non-normative tutorial. The third points to a description of a canonicalization algorithm for MBSML documents.

Purposes tend to be application specific. Table 42-2 lists those purposes that have been identified.

Table 42-2. RDDL Purposes

URI

Purpose

http://www.rddl.org/purposes#validation

DTD validation

http://www.rddl.org/purposes#schema-validation

Schema validation

http://www.rddl.org/purposes#module

DTD module

http://www.rddl.org/purposes#schema-module

Schema module

http://www.rddl.org/purposes#entities

Entity definition

http://www.rddl.org/purposes#notations

Notation definition

http://www.rddl.org/purposes#software-module

Software module

http://www.rddl.org/purposes#software-package

Software package

http://www.rddl.org/purposes#software-project

Software project

http://www.rddl.org/purposes#JAR

Java .jar file

http://www.rddl.org/purposes#software-directory

Software directory

http://www.rddl.org/purposes#reference

Documentation

http://www.rddl.org/purposes#normative-reference

Authoritative documentation

http://www.rddl.org/purposes#non-normative-reference

Nonauthoritative documentation

http://www.rddl.org/purposes#prior-version

A prior version

http://www.rddl.org/purposes#definition

Definition

http://www.rddl.org/purposes#icon

Icon

http://www.rddl.org/purposes#alternate

An alternate form

http://www.rddl.org/purposes#canonicalization

A canonicalization algorithm

http://www.rddl.org/purposes#directory

Another RDDL document

http://www.rddl.org/purposes#target

The namespace URL this document describes

Natures, purposes, and links together provide enough information for many processes to do something useful with a namespace URL, instead of merely using it as an opaque identifier. Even more importantly, putting HTML at the end of namespace URLs gives us curious humans something plausible to look at when we inevitably type the namespace URLs into web browsers.



Effective XML. 50 Specific Ways to Improve Your XML
Effective XML: 50 Specific Ways to Improve Your XML
ISBN: 0321150406
EAN: 2147483647
Year: 2002
Pages: 144

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net