org.hansel.probes
Class ACmpBranchProbe

java.lang.Object
  extended by org.hansel.Probe
      extended by org.hansel.probes.BranchProbe
          extended by org.hansel.probes.ACmpBranchProbe
All Implemented Interfaces:
junit.framework.Test

public class ACmpBranchProbe
extends BranchProbe

A probe for a comparing conditional branch. For decision coverage both possible conditions for the branch have to be encountered.

Author:
Niklas Mehner.

Field Summary
 
Fields inherited from class org.hansel.Probe
HIT_CLASS
 
Constructor Summary
ACmpBranchProbe(ProbeData pd, boolean equal)
           
 
Method Summary
 void hit(java.lang.Object obj1, java.lang.Object obj2)
          Called, when a probe is hit.
 void insertProbeCode(org.objectweb.asm.MethodVisitor cv)
          Returns the code of the probe.
 
Methods inherited from class org.hansel.probes.BranchProbe
cover, coverageFailure, displayFailure, getFailureMessage
 
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

ACmpBranchProbe

public ACmpBranchProbe(ProbeData pd,
                       boolean equal)
Method Detail

hit

public void hit(java.lang.Object obj1,
                java.lang.Object obj2)
Called, when a probe is hit.

Parameters:
obj1 - First object to be compared.
obj2 - Second object to be compared.

insertProbeCode

public void insertProbeCode(org.objectweb.asm.MethodVisitor cv)
Returns the code of the probe.

Specified by:
insertProbeCode in class Probe
Parameters:
cp - ConstantPool all names of methods etc. have to be inserted.