1 19 20 25 26 package soot.jimple.toolkits.annotation.arraycheck; 27 28 import soot.*; 29 import soot.jimple.*; 30 31 class MethodLocal 32 { 33 private SootMethod m; 34 private Local l; 35 36 public MethodLocal(SootMethod method, Local local) 37 { 38 m = method; 39 l = local; 40 } 41 42 public SootMethod getMethod() 43 { 44 return m; 45 } 46 47 public Local getLocal() 48 { 49 return l; 50 } 51 52 public int hashCode() 53 { 54 return m.hashCode()+l.hashCode(); 55 } 56 57 public boolean equals(Object other) 58 { 59 if (other instanceof MethodLocal) 60 { 61 MethodLocal another = (MethodLocal)other; 62 return m.equals(another.getMethod()) && l.equals(another.getLocal()) ; 63 } 64 65 return false; 66 } 67 68 public String toString() 69 { 70 return "["+m.getSignature()+" : "+l.toString()+"]"; 71 } 72 } 73 74 75 76 77 78 | Popular Tags |