Previous | Table of Contents | Next |
You have accomplished all the tasks related to document analysis. You now can add bells and whistlesextended featuresto your documents. The bells and whistles show up as more elements. This chapter shows you how to handle nonprinting (control) information. Its still basic SGML; it does not even push the envelope of SGMLs capabilities.
In this chapter, you learn:
When you add features to your documents, you add features to your document types. You must first decide which document types get which nonprinting (control) features. You take one document type at a time and decide all the features that it should have.
When you add features to a document type, you modify the document instance. You also must modify the DTD because you are dealing with all the document instances of that type. The DTD must conform to SGML and parse completely.
Note:
Be careful that the features you add to one type of document apply to all the instances of that document type. In the case of the HTML DTD, that could involve all the documents on the World Wide Web.If you modify document instances without modifying the agreed-upon DTDin this case, HTML version 2.0you run the risk of creating documents that cannot be viewed using standard HTML compliant browsers. This sort of problem is the seed of a current controversy on the Net: the conflict between innovation and standardization. The result is the rise of mutations of standard HTML documents that can only be viewed through proprietary browsers like Netscape.
See Standardization versus Innovation, p. 315 See Handling Tables and Handling Math and Equations, pp. 421, 424
Extending document architecture, therefore, involves modifying a DTD. You can add attributes to elements and add elements to the DTD. You can also add entities. This procedure might look like the following:
Using the HTML DTD as an example, suppose you wanted to add the ability to express complicated math equations to the HTML standard. (The proposed version 3.0 of the HTML DTD does this.) Since you have just one document type, this simplifies the process. But you first add a group of entities with which to express special math symbols. Then you must add elements that utilize these symbols in the required mathematical waysyou must add superscript and subscript elements, for example. In the case of HTML 3.0, there are structures to incorporate LaTex-like arrays for storing formatting macros to display complicated formulas. This whole architectural extension relies on a systematic modification of the DTD, as described earlier.
Figure 9.1 shows a graphical representation of how to extend document architecture.
Fig. 9.1 Extending document architecture involves adding features to the structure of a document type.
Before you add a feature to your document types, ask yourself these questions:
See The Definition Process, p. 137 See Choosing Elements or Attributes, Dealing with Mixed-Content Models, Dealing with Ambiguous Content Models, and How Flexible Should DTDs Be? pp. 247, 258, 259, 261
Tip:
When you design features, always keep in mind the people who will use them. Add the new features to your element dictionary, which records and explains all the elements that you have created for your documents and DTDs. Dont shortcut this task. The people who follow you in the project will need the information.
Documents often exist at several revision levels. The revision level can be critical, especially in engineering documents. People often deal with similar documents at different revision levels, and the revision level affects how a document must be processed.
Note:
Although many environments require revision tracking, engineering and manufacturing environments especially need the feature. If you expect to work on SGML documents in this type of environment, you should become an expert at adding features such as revision tracking to documents and DTDs.Any environment where different configurations of a product or of information can possibly be confused or mixed together incorrectly should probably include revision tracking. For example, if you are building one configuration of a software or hardware product for one customer, but a slightly different configuration for a different customer, you want to ensure each customer gets the correct documentation for his or her configuration. Revision tracking helps maintain compatibility.
Previous | Table of Contents | Next |