1 package Analysis.SSJava;
3 import java.util.HashMap;
4 import java.util.HashSet;
9 import IR.MethodDescriptor;
11 public class MethodLocationInfo extends LocationInfo {
15 CompositeLocation pcLoc;
18 Map<Integer, CompositeLocation> mapParamIdxToInferLoc;
19 Set<String> paramLocNameSet;
21 public MethodLocationInfo(MethodDescriptor md) {
23 this.paramLocNameSet = new HashSet<String>();
24 this.pcLoc = new CompositeLocation(new Location(md, Location.TOP));
25 this.mapParamIdxToInferLoc = new HashMap<Integer, CompositeLocation>();
28 public void addMapParamIdxToInferLoc(int paramIdx, CompositeLocation inferLoc) {
29 mapParamIdxToInferLoc.put(paramIdx, inferLoc);
32 public Map<Integer, CompositeLocation> getMapParamIdxToInferLoc() {
33 return mapParamIdxToInferLoc;
36 public String getGlobalLocName() {
40 public void setGlobalLocName(String globalLocName) {
41 this.globalLocName = globalLocName;
44 public String getReturnLocName() {
48 public void setReturnLocName(String returnLocName) {
49 this.returnLocName = returnLocName;
52 public String getThisLocName() {
56 public void setThisLocName(String thisLocName) {
57 this.thisLocName = thisLocName;
60 public CompositeLocation getPCLoc() {
64 public void setPCLoc(CompositeLocation pcLoc) {
68 public void removeMaplocalVarToLocSet(Descriptor localVarDesc) {
69 String localVarLocSymbol = localVarDesc.getSymbol();
70 getDescSet(localVarLocSymbol).remove(localVarDesc);