James K. Tauber
Standards
XML
DSSSL
FPI-URN resolution

Grove Notes

In both the transformation process and formatting process, DSSSL represents an SGML document or subdocument as a collection of nodes called a grove. A node is an ordered set of mappings (called property assignments) between property names and property values. Amongst other things, these mappings indicate the relationship between nodes in a grove.

Each node belongs to a particular class which determines what property names the node can have. Each property name in a node's property assigments corresponds to the name of a property of the class to which the node belongs. In addition to dictating what property names a node can have, the class determines the ordering of the property assignments. The property assigments of a node are in the same ordering as the properties of the class the node belongs to.

The extent to which a grove represents all the information in an SGML document can be controlled via a grove plan. A grove plan defines a set of classes and an ordered set of properties for each class. A grove built according to such a plan will contain only nodes in those classes. As a result, those nodes will only contain property assignments corresponding to those properties defined in the grove plan.

The properties of a class are drawn from a property set defined in a property set definition.

Properties may either be primative or nodal. Nodal properties take as their values nodes or lists or nodes. There are three nodal property types:

  • subnode property types
  • irefnode property types
  • urefnode property types

The subnode and irefnode property types take as their values nodes in the same grove as the node with the property. The subnode and irefnode properties connect all the nodes of a grove into a directed graph with the property names labelling the arcs of such a graph. More specifically, subnode properties connect all the nodes of a grove into a tree called a subnode tree.

A urefnode property value need not be in the same grove as the node with the property. The set of groves connected by such properties is called a hypergrove

Coming back to subnode properties. In each grove, there is a single node that doesn't appear in the value of any subnode properties. This node is the grove root. Every other node must appear in the value of a subnode property of some node. If a node n is included in the value of a subnode property p of node o then o is said to be the origin of n and p the orgin-to-subnode relationship of n. For a given n, o and p are unique.

Each class has a content property that is either primitive or nodal. If primitive, it must be of type char or string and is said to be the data property of the node. If nodal, it is said to be the children property of the node. The children of a node are those nodes included in the value of the children property. The parent of a node (if the node has one) will be its origin. For a node to have this parent, the origin must have a children property with the node included in its value.

If a node has a children property, the data of that node is the data of each of its children separated by the value of the class's data separator property if it exists.

Recall that a grove plan specifies a selection of classes and properties that are to be used in the building of a grove. If all the classes and properties of a property set are selected, the resultant grove is the complete grove.

A grove that results from a grove plan can be derived from the complete grove in the following manner:

  1. Starting at the grove root, recursively mark each node's subgrove. To mark the subgrove of a node, mark the node itself. Then, for each of the node's subnode properties that is included in the grove plan, mark the subgrove of each node in the properties value that is in a class included in the grove plan.
  2. [[bits about intrinsic properties skipped for now]]
  3. If a node has an irefnode property whose value in the complete grove is a node not marked for the grove being built, the value of that property in the grove being built will be null.
  4. Likewise, if the irefnode property has as its value a list of nodes, only those nodes marked are included in the value.

James K. Tauber / jtauber@jtauber.com
Last updated: 1997-4-10
http://www.jtauber.com/standards/dsssl/grove.html