Working Draft 2001-09-02
XNote 1.0 is a simple XML application that allows people to create documentation with certain special features - such as HyperText, annotations, and lists - especially for use on the World Wide Web.
This document is made available by the author as a note to the World Wide Web community. (c) Copyright 2001, Sean B. Palmer. Distribution of this document is unlimited, as long as no change whatsoever is made to the content. Citations may be made, as long as they are used in a sensible context, and include the URI and status of this working draft.
This document is based upon numerous previous works and conversations which may be lost in the mists of time. An attempt at crediting for this document is given in Appendix B.
XNote 1.0 is a language created in order to fulfil the need for a lightweight, repurposable, and easily transformable XML documentation format. XHTML and WML have not, in the authors opinion, fulfilled the interoperability requirements of the World Wide Web user base. This language is not intended to replace these languages, but instead offers a base format which can be stored on servers, and then served out according to the preferences of the user.
This specification defines two sets of attributes, "core attributes" and "main attributes".
The following are the core attributes:-
This includes all of the "core attributes" plus:-
Note that all elements may use the following set of content groups. The exact nature of these content groups will become clear when the names are defined later on in this specification. The names such as "annot" and "meta" in the following set of content groups are referred to in this specification as "modules". This is synonumous with the term "substitution group" in XML Schema, and basically consists of a set of elements which may be used.
The root element of all conforming XNote 1.0 documents must be
<xnote/>
in the XNote 1.0 namespace.
The following are the set of XNote 1.0 modules; sets of elements with common semantics. They have been aranged in this modular fashion for ease of use, comprehension to people reading this specification, and for reuse by other applications.
This module contains a set of elements which may be used to annotate their enclosing elements. That is to say, these set of elements always refers to their direct parent element. @@ Unary metadata.
This module contains a set of element which may be used to add scoped metadata to their enclosing element. Again, this set of elements always refer to their direct parent element. Where the parent element is the root element, this is said to refer to the whole document.
<data> - this attaches some literal metadata with an element, &/or extra information.
<info> - this element can be used to attach a URI to a document with a predicate. Much like an RDF triple, using the parent element as the subject, the rel attribute as a predicate, and the href value as an object.
These elements may both have "rel" and "rev" attributes. These attributes may be used on a variety of other elements in this specification too. They consist of a single QName, and are used to attach a property to the metadata relationship. For "rel" the property and value are attached to the document. For "rev" the property and document are attached to ythe value, i.e. the inverse of "rel". For example:-
<xnote ...> <data rel="c:myproperty">My data</data> <info rev="c:myprop" xlink:href="http://myuri.org/"/> </xnote>
attaches the literal data "My data" to the document using the
c:myproperty
QName as a QName, and the current document to the
resource identified by the URI http://myuri.org/
using the
property represented by the QName c:myprop
.
Note that all QNames appearing in XNote attributes use an RDF style concatenation mechanism, to resolve to a URI. Hence, the following elements are exactly the same:-
<data xmlns:c="http://myuri.org/#" rel="c:myprop">My data</data> <data xmlns:c="http://myuri.org/#my" rel="c:prop">My data</data>
and mean that the literal value "My data" is atached to the document using
the resource identified by the URI http://myuri.org/#myprop
as a
property. Processors must concatenate QNames in attributes in this fashion
when using them.
This specification sets out a number of special URIs for use in the rel and rev attributes.
This module contains a set of elements which allow for general classification.
This module contains a set of elements which allows one to create lists of items.
This module contains elements that allow one to include multimedia into ones document. This may include any material which has a MIME type and is available as a network retrivable entity in URI space. The mechanism for including this into ones document has been specially created so that metadata is required. This ensures that users who may not be able to access content of a certain modality can access alternaitves provided in another modality, or access a repurposable markup annotation of them.
This module contains elements that allow one to use basic text forms within a document.
This module contains a set of elements that allow people to add special forms of text to their basic text forms, including HyperText, emhpasis, and code markup spans.
The following characters are defined in [XML] as whitespace characters:-
The XML processor normalizes different system's line end codes into one single line-feed character, that is passed up to the application. Whitespace is handled according to the following rules:-
This specification makes no particular requirements as to User Agent rendering.
A fully conforming XNote 1.0 document is one which:-
Any document which does not meet these requirements is not a conforming instance of XNote 1.0.
No MIME type has yet been registered for XNote 1.0. We are thinking of
registering something like: application/prs.xnote+xml
. XNote
instances served using this MIME type may be processed as XML.
Thanks to Aaron Swartz, William Loughborough, Dan Connolly, Murray Altheim, and Al Gilman - all of whom did not contribute directly to this draft or even endorse it, but taghut me a lot about making decent languages.
The notation used throughout this specification is a proprietary one, designed to get across the general structure of the language to the reader in a clear and efficient manner, basded upon DTDs. It's designed for people who can read DTDs already to pick it up more or less instantly.
The parts are not normative; the only normative content model is the XML Schema. Notwithstanding that, the patterns are the most useful thing to learn the language from and so here is a brief overview of what it means:-
?
", "+
" and "*
" mean the
same things (0 or 1 occurances, 1 or more occurances, and 0 or more
occurances respectively), as do ",
" and "|
"
("followed by" and "or" respectively).#
" (e.g.
"#(mypattern)*
") may contain #PCDATA per the XML
specification. Patterns for groups may not start with a
"#
".Example:-
<a>, <b> (grp.c|(d,e,f)+)?
Element "<a>" and element "b" may contain either "grp.c", or "d" followed by "e" followed by "f" 1 or more times, 0 or 1 times.
Sean B. Palmer