1 package Analysis.Pointer;
3 import Analysis.Disjoint.PointerMethod;
4 import Analysis.Pointer.AllocFactory.AllocNode;
8 /* This is field is set is this Graph is just a delta on the parent
12 HashMap<AllocNode, HashSet<Edge>> nodeMap;
13 HashMap<TempDescriptor, HashSet<Edge>> varMap;
14 HashMap<AllocNode, HashSet<Edge>> backMap;
15 HashSet<Edge> strongUpdateSet;
17 public Graph(Graph parent) {
18 nodeMap=new HashMap<AllocNode, HashSet<Edge>>();
19 backMap=new HashMap<AllocNode, HashSet<Edge>>();
20 varMap=new HashMap<TempDescriptor, HashSet<Edge>>();
24 public HashSet<Edge> getEdges(TempDescriptor tmp) {
25 if (varMap.containsKey(tmp))
26 return varMap.get(tmp);
27 else if (parent!=null&&parent.varMap.containsKey(tmp))
28 return parent.varMap.get(tmp);
32 public HashSet<Edge> getEdges(AllocNode node) {
33 if (nodeMap.containsKey(node))
34 return nodeMap.get(node);
35 else if (parent!=null&&parent.nodeMap.containsKey(node))
36 return parent.nodeMap.get(node);
40 public static HashSet<Edge> emptySet=new HashSet<Edge>();