IP Library Granted Patent US 7,117,216
Granted Patent B2
US 7,117,216 · App. 10/038,203 · Granted Oct 3, 2006

Method and apparatus for runtime merging of hierarchical trees

View Patent ↗
Loading inventors, assignments & file history…
Monitor This Case
Get email alerts when status or documents change.
Order Certified Copies
Most orders are placed with the USPTO same day — all within 24 business hours.
Order via The Patent Place →
Pre-filled with this patent's details
Quick Facts
Patent No.
US 7,117,216
App. No.
10/038,203
Granted
Oct 3, 2006
Kind
B2
Abstract

Embodiments of the present invention relate to a method and apparatus for a runtime merging system of hierarchical trees with a reference node implementation. According to one or more embodiments of the present invention, a reference node is implemented which holds a reference to a node in a DOM tree active in memory. The reference node class allows adding nodes to the merged tree without having to make a clone of the node, which is an expensive operation. In one embodiment, if a particular node is not present below a certain level of the tree in any layer except a unique layer, it renders visiting the children of that node unnecessary. A reference is kept to the node in the memory.

Claims (65)

1. A method in a data processing system comprising:

examining nodes in a plurality of hierarchical trees;

determining if a node is present in only one tree by comparing two or more of the hierarchical trees;

creating a merged tree based on the nodes in the hierarchical trees;

determining if the hierarchical trees comprise a set of equivalent nodes

selecting a node with the highest priority from the set of equivalent nodes if the hierarchical trees comprise a set of equivalent nodes;

creating a shallow clone of the selected node; and

adding the shallow clone to the merged tree.

2. The method of claim 1 further comprising:

creating a reference node to the node determined to be present in only one tree if a node is determined to be present in only one tree; and

adding the reference node to the merged tree.

3. The method of claim 2 wherein the reference node is a pointer.

4. The method of claim 2 wherein the reference node is a Java reference.

5. The method of claim 1 wherein the hierarchical trees comprise a group tree and a user tree.

6. The method of claim 1 wherein the hierarchical trees comprise a group tree and an admin tree.

7. The method of claim 1 wherein the hierarchical trees comprise a user tree and an admin tree.

8. The method of claim 1 wherein the hierarchical trees comprise a group tree, a user tree, and an admin tree.

9. The method of claim 1 wherein the hierarchical trees are DOM trees.

10. The method of claim 9 wherein the DOM trees are XML DOM trees.

11. The method of claim 1 further comprising:

printing the merged tree.

12. A data processing computer comprising:

a memory comprising a program that:

examines nodes in a plurality of hierarchical trees;

determines if a node is present in only one tree by comparing two or more of the hierarchical trees;

creates a merged tree based on the nodes in the hierarchical trees;

determines if the hierarchical trees comprise a set of equivalent nodes;

selects a node with the highest priority from the set of equivalent nodes if the hierarchical trees comprise a set of equivalent nodes;

creates a shallow clone of the selected node; and

adds the shallow clone to the merged tree; and

a processor for running the program.

13. The data processing computer of claim 12 wherein the program further:

creates a reference node to the node determined to be present in only one tree if a node is determined to be present in only one tree; and

adds the reference node to the merged tree.

14. The data processing computer of claim 13 wherein the reference node is a pointer.

15. The data processing computer of claim 13 wherein the reference node is a Java reference.

16. The data processing computer of claim 12 wherein the hierarchical trees comprise a group tree and a user tree.

17. The data processing computer of claim 12 wherein the hierarchical trees comprise a group tree and an admin tree.

18. The data processing computer of claim 12 wherein the hierarchical trees comprise a user tree and an admin tree.

19. The data processing computer of claim 12 wherein the hierarchical trees comprise a group tree, a user tree, and an admin tree.

20. The data processing computer of claim 12 wherein the hierarchical trees are DOM trees.

21. The data processing computer of claim 20 wherein the DOM trees are XML DOM trees.

22. The data processing computer of claim 12 wherein the program further:

prints the merged tree.

23. A computer-readable medium storing computer-readable instructions for controlling a data processing system to perform a method comprising the steps of:

examining nodes in a plurality of hierarchical trees;

determining if a node is present in only one tree by comparing two or more of the hierarchical trees; and

creating a merged tree based on the nodes in the hierarchical trees;

determining if the hierarchical trees comprise a set of equivalent nodes;

selecting a node with the highest priority from the set of equivalent nodes if the hierarchical trees comprise a set of equivalent nodes;

creating a shallow clone of the selected node; and

adding the shallow clone to the merged tree.

24. The computer-readable medium of claim 23 wherein the method further comprises the steps of:

creating a reference node to the node determined to be present in only one tree if a node is determined to be present in only one tree; and

adding the reference node to the merged tree.

25. The computer-readable medium of claim 24 wherein the reference node is a pointer.

26. The computer-readable medium of claim 24 wherein the reference node is a Java reference.

27. The computer-readable medium of claim 23 wherein the hierarchical trees comprise a group tree and a user tree.

28. The computer-readable medium of claim 23 wherein the hierarchical trees comprise a group tree and an admin tree.

29. The computer-readable medium of claim 23 wherein the hierarchical trees comprise a user tree and an admin tree.

30. The computer-readable medium of claim 23 wherein the hierarchical trees comprise a group tree, a user tree, and an admin tree.

31. The computer-readable medium of claim 23 wherein the hierarchical trees are DOM trees.

32. The computer-readable medium of claim 31 wherein the DOM trees are XML DOM trees.

33. The computer-readable medium of claim 23 wherein the method further comprises the step of:

printing the merged tree.

Assignments (2)
MERGER AND CHANGE OF NAME Recorded Dec 16, 2015
From: ORACLE USA, INC.; SUN MICROSYSTEMS, INC.; ORACLE AMERICA, INC.
To: ORACLE AMERICA, INC.
Reel/Frame 037302/0616 →
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Oct 19, 2001
From: CHAKRABORTY, KRISHNENDU; WONG, AMY; HEILIG, JOERG
To: SUN MICROSYSTEMS, INC.
Reel/Frame 012460/0932 →