Lists Home |
Date Index |
- From: Richard Light <email@example.com>
- To: firstname.lastname@example.org
- Date: Mon, 21 Jul 1997 09:36:06 +0100
In message <33D19C41.41E547CD@datachannel.com>, John Tigue
>I would like to propose an addition to Xapi-J which would be the start
>of the interface to a document.
>The current definition of Xapi-J focuses on the interface IXMLProcessor
>and its method readXML() which returns a reference to an IElement which
>represents the root element of the processed document. This choice was
>made simply because it reflected the lowest common denominator of the
>currently available XML processors. The results are proving to be
>For example, a processor might construct a representation of the entire
>document including any internal DTD. As Xapi-J currently stands, the DTD
>representation would not be accessible because only the root element is
>returned from readXML() rather than a reference to the entire document.
>Perhaps it would be better to return a reference to the document. The
>root would then be available through, say, IDocument.getRoot(). As such
>I would like to propose the following beginning to IDocument:
(Read 'XML' for 'SGML' throughout!)
This is exactly the sort of problem which adopting the 'grove plan'
approach is meant to deal with. In line with your suggestion, the SGML
property set starts with the class sgmldoc, or 'SGML document', which is
'the parsed SGML document. The root of the grove.'
This is _not_ the root element of the document instance: the 'document
element' is just one of the properties of the sgmldoc class. sgmldoc
has the following properties that might be relevant to XAPI:
- prolog (as per XML's 'prolog' - contains the internal and external
- epilog (equivalent to the 'Misc*' which follows the document
- docelem ('document element' - the root element of the document
- elements (all the elements in the document which have unique
identifiers - handy for processing XPointers, etc.);
- entities (the explicitly declared general entities, followed by the
(There are others!)
Putting it less formally, the SGML property set matches all the concepts
which are defined in XML. Thus the XML production  for 'document':
document ::= Prolog element Misc*
is equivalent to the sgmldoc class, which in turn has properties which
are equivalent to 'Prolog' (prolog), 'element' (docelem) and 'Misc*'
In my view, XAPI should be taking advantage of this existing framework
(and naming conventions) where it is relevant to XML's requirements.
Didn't someone do a summary of the relevant classes and properties a
couple of months back?
SGML and Museum Information Consultancy
3 Midfields Walk
West Sussex RH15 8JA
tel. (44) 1444 232067
xml-dev: A list for W3C XML Developers
Archived as: http://www.lists.ic.ac.uk/hypermail/xml-dev/
To unsubscribe, send to email@example.com the following message;
List coordinator, Henry Rzepa (firstname.lastname@example.org)