+ System.out.println("#INDENTIFY WHICH METHOD...");
+ // identify which method in the inheritance chain has the highest PCLOC
+ // basically, finds a method that has the highest count or TOP location
+ int highestCount = -1;
+ MethodDescriptor methodDescHighestCount = null;
+ for (Iterator iterator2 = methodDescSet.iterator(); iterator2.hasNext();) {
+ MethodDescriptor methodDesc = (MethodDescriptor) iterator2.next();
+ if (mapMethodDescToParamCount.containsKey(methodDesc)) {
+ int curCount = mapMethodDescToParamCount.get(methodDesc).intValue();
+ if (highestCount < curCount) {
+ highestCount = curCount;
+ methodDescHighestCount = methodDesc;
+ }
+ }
+ }
+
+ if (methodDescHighestCount != null) {
+ FlowGraph flowGraph = getFlowGraph(methodDescHighestCount);
+ CompositeLocation pcLOC = getMethodSummary(methodDescHighestCount).getPCLoc();
+ FlowNode pcFlowNode = flowGraph.getFlowNode(translateToDescTuple(pcLOC.getTuple()));
+ Set<FlowNode> reachableSet =
+ flowGraph.getReachableSetFrom(pcFlowNode.getCurrentDescTuple().subList(0, 1));
+
+ Set<FlowNode> reachableParamNodeSet = new HashSet<FlowNode>();
+ for (Iterator iterator3 = reachableSet.iterator(); iterator3.hasNext();) {
+ FlowNode flowNode = (FlowNode) iterator3.next();
+ if (flowGraph.isParameter(flowNode.getCurrentDescTuple())) {
+ reachableParamNodeSet.add(flowNode);
+ }
+
+ System.out.println(flowNode + " is PARAM="
+ + flowGraph.isParameter(flowNode.getCurrentDescTuple()));
+ }
+
+ Set<NTuple<Descriptor>> descTupleSetLowerThanPC = new HashSet<NTuple<Descriptor>>();
+ for (Iterator iterator2 = reachableParamNodeSet.iterator(); iterator2.hasNext();) {
+ FlowNode flowNode = (FlowNode) iterator2.next();
+ descTupleSetLowerThanPC.add(flowNode.getCurrentDescTuple());
+ }
+
+ // mapHighestOverriddenMethodDescToPCLocTuple.remove(highestMethodDesc);
+ mapHighestOverriddenMethodDescToSetLowerThanPCLoc.put(highestMethodDesc,
+ descTupleSetLowerThanPC);
+ }