1 29 package jegg.btree; 30 31 34 public class Node 35 { 36 private int position; 37 private Object object; 38 private Node lesser = null; 39 private Node greater = null; 40 41 public Node(int i, Object o) 42 { 43 position = i; 44 object = o; 45 } 46 public int getPosition() 47 { 48 return position; 49 } 50 public Object getObject() 51 { 52 return object; 53 } 54 public void setObject(Object o) 55 { 56 object = o; 57 } 58 public Node getLesser() 59 { 60 return lesser; 61 } 62 public void setLesser(Node n) 63 { 64 lesser = n; 65 } 66 public Node getGreater() 67 { 68 return greater; 69 } 70 public void setGreater(Node n) 71 { 72 greater = n; 73 } 74 } 75 | Popular Tags |