In the Metacat DOM implementation XML documents
are disassembled in their composing nodes. All nodes are stored as records
in relational database tables. The structure of each XML document is preserved
by saving parent-child relationship between the nodes.
- Each XML document in the Metacat database starts with one root node of
type DOCUMENT. All other nodes in the document are its children.
The document node can
have multiple COMMENT or PI (processing instruction) nodes and only
one ELEMENT node. The element node is the root node of the document and will
be pointed to by all of its children.
- Each node is described as a single record in the xml_nodes table.
All nodes have a unique System ID (nodeid). Each node stores
the ID of
its direct parent (in parentnodeid), the ID of its documents root node
(in rootnodeid) and its Document ID (docid).
- Document attributes (such as docid, doctype, etc.) are stored in
the xml_documents table.
- Unimplemented DOM features:
- Node types: Doctype, Entity, EntityReference, Notation.
- Persistant DOM interface. This would allow a DOM compliant
editor to work with an xml document in the database as if it were
in memory.
- Object Oriented representation of each node.
Back | Home |
Next