Lists Home |
Date Index |
- From: "David G. Durand" <email@example.com>
- To: XML Dev <firstname.lastname@example.org>
- Date: Tue, 11 Aug 1998 13:10:38 -0400
At 10:36 AM -0400 8/11/98, John Cowan wrote:
>But note that Java uses the model of the old draft: all minimization
>declarations ("import" statements in Java jargon) must appear at the
>beginning, and are global to the document.
The equivalent to this policy for XML would be for the "minimization
declarations" to be local to the _entity_. This idea was discussed, but
found lacking. The equivalent to the old mechanism would be if a
declaration in one storage unit (Java file) could affect code in other
storage units (Java files). In XML, under the original proposal, the root
entity was privileged and the only one that could declare prefixes; no way
was provided to prevent those prefixes from colliding with prefixes in
other external entities.
A Java file isn't a complete Java program, any more than an XML entity is a
complete document. Careful consideration of the implications of adopting
entity-based scoping led to the conclusion that it's more confusing, and
harder to implement on top of things like SAX.
Local declarations _allow_ the avoidance of prefix conflicts without
_requiring_ any problems in validation. There's a tradeoff to be made. One
can even keep validation and local declarations, if say, a particular
element (say <Dublin:metadata>) is always intended to hold information in a
particular namespace. The element could have a #FIXED declaration in the
DTD (or internal subset) and still validate just fine.
Global declarations can still cause problems with validation, but _don't_
provide any way to manage prefixes to avoid collisions, especially in the
case where validation is not an issue. The level of effort required for
validation is higher, and it's certainly not the case that namespaces will
_allow_ lots of incorrect _valid_ documents. They may make some "correct"
documents invalid, but that was always a potential problem with namespaces,
especially when used as an instance-fragment combining mechanism.
David Durand email@example.com \ david@dynamicDiagrams.com
Boston University Computer Science \ Sr. Analyst
http://www.cs.bu.edu/students/grads/dgd/ \ Dynamic Diagrams
MAPA: mapping for the WWW \__________________________
xml-dev: A list for W3C XML Developers. To post, mailto:firstname.lastname@example.org
Archived as: http://www.lists.ic.ac.uk/hypermail/xml-dev/
To (un)subscribe, mailto:email@example.com the following message;
To subscribe to the digests, mailto:firstname.lastname@example.org the following message;
List coordinator, Henry Rzepa (mailto:email@example.com)