home | O'Reilly's CD bookshelfs | FreeBSD | Linux | Cisco | Cisco Exam    

Book HomeXML in a NutshellSearch this book

14.3. Natures

The nature of a related resource says what the resource is. For example, the nature of a web page might be HTML, and the nature of an image might be JPEG. The nature is indicated by a URL. Normally this nature URL is a namespace URL for XML applications and a MIME media type URL for everything else. For instance, the XSLT nature is written as http://www.w3.org/1999/XSL/Transform. The JPEG nature is written as http://www.isi.edu/in-notes/iana/assignments/media-types/image/jpeg.

The RDDL specification specifies two dozen natures that can be used in xlink:role attributes. In addition, you are welcome to define your own, but when possible, you should use the standard natures so that automated software can understand your documents and locate the related resources it needs to locate. These are the standard natures and their URLs:

CSS stylesheet

http://www.isi.edu/in-notes/iana/assignments/media-types/text/css

DTD

http://www.isi.edu/in-notes/iana/assignments/media-types/application/xml-dtd

A mailbox

http://www.rddl.org/natures#mailbox

Generic HTML

http://www.isi.edu/in-notes/iana/assignments/media-types/text/html

HTML 4.0

http://www.w3.org/TR/html4/

HTML 4 Strict

http://www.w3.org/TR/html4/strict

HTML 4 Transitional

http://www.w3.org/TR/html4/transitional

HTML 4 Frameset

http://www.w3.org/TR/html4/frameset

XHTML

http://www.w3.org/1999/xhtml

XHTML 1.0 Strict

http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict

XHTML 1.0 Transitional

http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional

RDF schema

http://www.w3.org/2000/01/rdf-schema#

RELAX core grammar

http://www.xml.gr.jp/xmlns/relaxCore

RELAX namespace grammar

http://www.xml.gr.jp/xmlns/relaxNamespace

Schematron schema

http://www.ascc.net/xml/schematron

OASIS Open Catalog

http://www.rddl.org/natures#SOCAT

W3C XML Schema Language schema

http://www.w3.org/2000/10/XMLSchema

XML character data

http://www.w3.org/TR/REC-xml.html#dt-chardata

XML escaped text

http://www.w3.org/TR/REC-xml.html#dt-escape

XML unparsed entity

http://www.w3.org/TR/REC-xml.html#dt-unparsed

IETF RFC

http://www.ietf.org/rfc/rfc2026.txt

ISO standard

http://www.iso.ch/

Python software

http://www.rddl.org/natures/software#python

Java software

http://www.rddl.org/natures/software#java

Many other natures can be reasonably derived by following these examples. For instance, a PNG image could be given the nature because http://www.isi.edu/in-notes/iana/assignments/media-types/image/png because PNG documents have the MIME media type image/png. Software written in Ruby could be given the nature http://www.rddl.org/natures/software#ruby. An RDF document can have the nature http://www.w3.org/1999/02/22-rdf-syntax-ns# taken from its namespace, and so forth.



Library Navigation Links

Copyright © 2002 O'Reilly & Associates. All rights reserved.











??????????????@Mail.ru