Unspecified #IMPLIED attributes in Java

Paul Prescod papresco at technologist.com
Fri Dec 19 17:00:00 GMT 1997


Toby Speight wrote:
> 
> If I write a {grove, tree} builder, it would be useful to know whether
> a DTD was used, so that it can report an error to an application trying
> to access an attribute that was not declared (this may be the symptom
> of a typo, perhaps).  If a DTD was not used for the parse, then the
> access should return null (as if the attribute were declared #IMPLIED).

The DSSSL model is that trying to access a random attribute merely
returns #f. Although this could allow a typo to pass, it has the benefit
of making stylesheets a little more robust to DTD variations. For
instance, the same stylesheet can work with various versions of HTML.

 Paul Prescod



xml-dev: A list for W3C XML Developers. To post, mailto:xml-dev at ic.ac.uk
Archived as: http://www.lists.ic.ac.uk/hypermail/xml-dev/
To (un)subscribe, mailto:majordomo at ic.ac.uk the following message;
(un)subscribe xml-dev
To subscribe to the digests, mailto:majordomo at ic.ac.uk the following message;
subscribe xml-dev-digest
List coordinator, Henry Rzepa (mailto:rzepa at ic.ac.uk)




More information about the Xml-dev mailing list