Lists Home |
Date Index |
- To: XML DEV <firstname.lastname@example.org>
- Subject: Re: Namespace dispatching
- From: Patrick Stickler <email@example.com>
- Date: Wed, 20 Feb 2002 16:07:07 +0200
- In-reply-to: <3C725B10.EDBDA384@prescod.net>
- User-agent: Microsoft-Entourage/10.0.0.1309
On 2002-02-19 16:02, "ext Paul Prescod" <firstname.lastname@example.org> wrote:
> "Which of the following are appropriate triggers for determining the
> document type of an XML document when metadata is unavailable:
> 1 DOCTYPE statement
> 2 top-level namespace
> I have not seen a compelling use-case for anything other than 1 and 2.
#2 is ruled out by cases where the same root element may
occur in multiple document models with differing content model
definitions (having only consistent semantics, but not
I.e. when there is not a 1:1 correspondence between namespace
and document model.
Such as XHTML 1.0 Strict, Transitional, and Frameset document
types, all of which have the same namespace and nearly identical
vocabulary but not identical content models.
One is unnable to determine from a top level element
which document model is being used.
The only way to know which document model applies to a particular
XML instance is to specify the actual document model explicitly.
In the absence of other metadata, the DOCTYPE declaration appears
the only (and most reasonable) choice. After all, that's what it's
In order to address modularity, an alterative to an instance-wide
DOCTYPE declarations might be an XML attribute such as xml:doctype
which takes a PUBLIC URI value, allowing folks to specify, even for
modular fragments, which document models apply to which sub-trees
of the XML instance. E.g.
The only remaining issue to be resolved is to make PUBLIC identifiers
schema-formalism independent, so that ideally, we'd have something
akin to the more general PUBLIC identifier (sans 'DTD+')
to which one might have a choice of resolving to DTD, XML Schema,
RELAX NG, etc. all of which define the document model in question.
By declaring the doctype in the actual element, this allows for
modular "islands" that may be validated independently of their
context and it is clear specifically which document model applies.
Patrick Stickler Phone: +358 50 483 9453
Senior Research Scientist Fax: +358 7180 35409
Nokia Research Center Email: email@example.com