摘要 |
A computer system and method edits a hierarchical document that has starttags and endtags and leaf contents between ones of the starttags and endtags. The computer system includes a memory, a user interface, and a hierarchical document editor. The memory stores a data structure representing the hierarchical document. The data structure includes an array of items and a corresponding index and a corresponding index offset for each of the items. Each of the items represents a corresponding one of the starttags, endtags, and leaf contents. The user interface displays the hierarchical document. It also issues commands for editing the hierarchical document. The hierarchical document editor edits the hierarchical document in response to the issued commands by traversing ones of the items in the data structure based on the indexes and index offsets of the traversed ones of the items./!
|