[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
No Subject
Hi,
After traversing through all the
methods in the allication
sootClass.getMethods() return methods in the
sootClass
plus the methods in it's super class.
Here is a portion of the code that I'm talkign
about:
String phase = "wjtp.profiler";
Iterator classesIt =
Scene.v().getApplicationClasses().iterator();
while (classesIt.hasNext())
{
SootClass sClass =
(SootClass)classesIt.next();
Object[] methodIt = sClass.getMethods().toArray(); // Using Iterator has the
same
affect
SootMethod method =
null;
for(int i = 0; i < methodIt.length; i++)
{
try{
method =
(SootMethod)methodIt[i];
if (!Modifier.isNative(method.getModifiers()) && method.isConcrete()
&& !method.hasActiveBody())
method.setActiveBody((JimpleBody)method.getBodyFromMethodSource(phase));
}catch(Exception
e){
System.out.println("Err assigning body to " + method + "\n\tThere may be
more problems
ahead.");
}
}
}
after running this code whenever I call
sootClass.getMethods() i get all methods
even the ones that are in the super class of
sootClass.
I've been using soot for quite a long time now and
I've never seen
this happen. Please help me, what could be causing
it? I'm using
JVM 1.4 and soot 1.2.3, But this also occurs with
JVM 1.3.1 and
soot 1.2.2
Thanks.
Mike.
- Follow-Ups:
- Re:
- From: "Mike" <trevize@softhome.net>