Пример #1
0
 public void go() {
   Iterator methods = cg.sourceMethods();
   while (methods.hasNext()) {
     SootMethod m = (SootMethod) methods.next();
     dfsVisit(m);
   }
 }
Пример #2
0
 private void dfsVisit(SootMethod m) {
   if (visited.contains(m)) return;
   visited.add(m);
   Iterator targets = new Targets(cg.edgesOutOf(m));
   while (targets.hasNext()) {
     SootMethod target = (SootMethod) targets.next();
     dfsVisit(target);
   }
   order.add(m);
 }