org.hansel.probes
Class MethodProbe

java.lang.Object
  extended by org.hansel.Probe
      extended by org.hansel.probes.MethodProbe
All Implemented Interfaces:
junit.framework.Test
Direct Known Subclasses:
ExceptionProbe

public class MethodProbe
extends Probe

A simple Probe that is placed in the instrumented code.

Author:
Niklas Mehner.

Field Summary
 
Fields inherited from class org.hansel.Probe
HIT_CLASS
 
Constructor Summary
MethodProbe(ProbeData pd)
          Create a new Probe.
 
Method Summary
 boolean coverageFailure()
           
 boolean displayFailure()
           
 java.lang.String getFailureMessage()
           
 void hit()
          Called by the ProbeTable, when this Probe is encountered by the instrumented code.
 void insertProbeCode(org.objectweb.asm.MethodVisitor cv)
          Returns the code of the probe.
 
Methods inherited from class org.hansel.Probe
addResult, countTestCases, equals, getDescription, getID, getName, getProbeData, hashCode, run, run, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

MethodProbe

public MethodProbe(ProbeData pd)
Create a new Probe.

Parameters:
pd - Data for this probe.
Method Detail

displayFailure

public boolean displayFailure()
Specified by:
displayFailure in class Probe

coverageFailure

public boolean coverageFailure()
Specified by:
coverageFailure in class Probe

getFailureMessage

public java.lang.String getFailureMessage()
Specified by:
getFailureMessage in class Probe

insertProbeCode

public void insertProbeCode(org.objectweb.asm.MethodVisitor cv)
Description copied from class: Probe
Returns the code of the probe.

Specified by:
insertProbeCode in class Probe

hit

public void hit()
Called by the ProbeTable, when this Probe is encountered by the instrumented code.