01: package net.sourceforge.jrefactory.query;
02:
03: import net.sourceforge.jrefactory.ast.Node;
04:
05: /**
06: * Description of where the search ended. The results
07: * include the node where the search found the parse
08: * tree and the index into the children of that node.
09: *
10: *@author Chris Seguin
11: */
12: public class Found {
13: private Node root;
14: private int index;
15:
16: /**
17: * Constructor for the Found object
18: *
19: *@param initRoot Description of Parameter
20: *@param initIndex Description of Parameter
21: */
22: public Found(Node initRoot, int initIndex) {
23: root = initRoot;
24: index = initIndex;
25: }
26:
27: /**
28: * Gets the Index attribute of the Found object
29: *
30: *@return The Index value
31: */
32: public int getIndex() {
33: return index;
34: }
35:
36: /**
37: * Gets the Root attribute of the Found object
38: *
39: *@return The Root value
40: */
41: public Node getRoot() {
42: return root;
43: }
44: }
|