public class ClassAnalyzer extends ClassProbesVisitor
Constructor and Description |
---|
ClassAnalyzer(long classid,
boolean[] probes,
StringPool stringPool)
Creates a new analyzer that builds coverage data for a class.
|
Modifier and Type | Method and Description |
---|---|
ClassCoverageImpl |
getCoverage()
Returns the coverage data for this class after this visitor has been
processed.
|
void |
visit(int version,
int access,
String name,
String signature,
String superName,
String[] interfaces) |
MethodProbesVisitor |
visitMethod(int access,
String name,
String desc,
String signature,
String[] exceptions)
When visiting a method we need a
MethodProbesVisitor to handle
the probes of that method. |
void |
visitSource(String source,
String debug) |
void |
visitTotalProbeCount(int count)
Reports the total number of encountered probes.
|
public ClassAnalyzer(long classid, boolean[] probes, StringPool stringPool)
classid
- id of the classprobes
- execution data for this class or null
stringPool
- shared pool to minimize the number of String
instancespublic ClassCoverageImpl getCoverage()
public void visit(int version, int access, String name, String signature, String superName, String[] interfaces)
visit
in class org.objectweb.asm.ClassVisitor
public void visitSource(String source, String debug)
visitSource
in class org.objectweb.asm.ClassVisitor
public MethodProbesVisitor visitMethod(int access, String name, String desc, String signature, String[] exceptions)
ClassProbesVisitor
MethodProbesVisitor
to handle
the probes of that method.visitMethod
in class ClassProbesVisitor
public void visitTotalProbeCount(int count)
ClassProbesVisitor
ClassVisitor.visitEnd()
. For interfaces
this method is called before the first method (the static initializer) is
emitted.visitTotalProbeCount
in class ClassProbesVisitor
count
- total number of probesCopyright © 2013. All Rights Reserved.