soot.baf.toolkits.base
Class ExamplePeephole

java.lang.Object
  extended by soot.baf.toolkits.base.ExamplePeephole
All Implemented Interfaces:
Peephole

public class ExamplePeephole
extends Object
implements Peephole

Example peephole that remove all checkcast operations. Resulting class will likely not verify.


Constructor Summary
ExamplePeephole()
           
 
Method Summary
 boolean apply(Body b)
          Entry point for a peephole.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ExamplePeephole

public ExamplePeephole()
Method Detail

apply

public boolean apply(Body b)
Description copied from interface: Peephole
Entry point for a peephole. This method is repeatly called by the peephole driver, until a fixed-point is reached over all peepholes.

Specified by:
apply in interface Peephole
Parameters:
b - Body to apply peephole to.
Returns:
true if the peephole changed in any way the Body it acted on. false otherwise.