Package soot.toolkits.graph.pdg
Class Region
- java.lang.Object
-
- soot.toolkits.graph.pdg.Region
-
- All Implemented Interfaces:
IRegion
public class Region extends Object implements IRegion
This class was originally designed to represent a weak region. Later, PDGRegion was designed to represent a richer region representation but since there were cases that we wanted to enforce the use of Region instead of PDGRegion, and for some other compatibility issues, we chose not to eliminate this class and even not to factor it into a common abstract class. One major contributing factor to the above is that, a Region can exist independent from a PDG since they are generated by RegionAnalysis, whereas a PDGRegion is generated by a PDG.- Author:
- Hossein Sadat-Mohtasham Jan 2009
-
-
Constructor Summary
Constructors Constructor Description Region(int id, List<Block> blocks, SootMethod m, SootClass c, UnitGraph ug)Region(int id, SootMethod m, SootClass c, UnitGraph ug)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidadd(Block b)voidadd2Back(Block b)voidaddChildRegion(IRegion chr)Objectclone()List<Block>getBlocks()List<IRegion>getChildRegions()UnitgetFirst()intgetID()UnitgetLast()IRegiongetParent()SootClassgetSootClass()SootMethodgetSootMethod()UnitGraphgetUnitGraph()List<Unit>getUnits()List<Unit>getUnits(Unit from, Unit to)booleanoccursBefore(Unit u1, Unit u2)voidremove(Block b)voidsetParent(IRegion pr)StringtoString()
-
-
-
Constructor Detail
-
Region
public Region(int id, SootMethod m, SootClass c, UnitGraph ug)
-
Region
public Region(int id, List<Block> blocks, SootMethod m, SootClass c, UnitGraph ug)
-
-
Method Detail
-
getSootMethod
public SootMethod getSootMethod()
- Specified by:
getSootMethodin interfaceIRegion
-
getSootClass
public SootClass getSootClass()
- Specified by:
getSootClassin interfaceIRegion
-
getUnitGraph
public UnitGraph getUnitGraph()
- Specified by:
getUnitGraphin interfaceIRegion
-
add
public void add(Block b)
-
add2Back
public void add2Back(Block b)
-
remove
public void remove(Block b)
-
occursBefore
public boolean occursBefore(Unit u1, Unit u2)
- Specified by:
occursBeforein interfaceIRegion
-
addChildRegion
public void addChildRegion(IRegion chr)
- Specified by:
addChildRegionin interfaceIRegion
-
getChildRegions
public List<IRegion> getChildRegions()
- Specified by:
getChildRegionsin interfaceIRegion
-
-