Package ptolemy.copernicus.kernel
Class NullPointerAnalysis
- java.lang.Object
-
- soot.toolkits.scalar.AbstractFlowAnalysis<N,A>
-
- soot.toolkits.scalar.BranchedFlowAnalysis<soot.Unit,A>
-
- soot.toolkits.scalar.ForwardBranchedFlowAnalysis
-
- soot.jimple.toolkits.annotation.nullcheck.BranchedRefVarsAnalysis
-
- ptolemy.copernicus.kernel.NullPointerAnalysis
-
public class NullPointerAnalysis extends soot.jimple.toolkits.annotation.nullcheck.BranchedRefVarsAnalysis
An analysis that can determine, at any point in the code, if a local variable points to null. This is just a nice wrapper class for soot's BranchedRefVarsAnalysis.- Since:
- Ptolemy II 4.0
- Version:
- $Id$
- Author:
- Steve Neuendorffer
- Pt.AcceptedRating:
- Red (cxh)
- Pt.ProposedRating:
- Red (cxh)
-
-
Field Summary
-
Fields inherited from class soot.jimple.toolkits.annotation.nullcheck.BranchedRefVarsAnalysis
emptySet, fullSet, kBottom, kNonNull, kNull, kTop, refTypeInstFieldBases, refTypeInstFields, refTypeLocals, refTypeStaticFields, refTypeValues, tempFlowSet, unitToAnalyzedChecksSet, unitToArrayRefChecksSet, unitToGenerateSet, unitToInstanceFieldRefChecksSet, unitToInstanceInvokeExprChecksSet, unitToLengthExprChecksSet, unitToPreserveSet
-
-
Constructor Summary
Constructors Constructor Description NullPointerAnalysis(soot.toolkits.graph.UnitGraph g)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
isAlwaysNullBefore(soot.Local local, soot.Unit unit)
Return the set of other fields and locals that must reference the same object as the given field, at a point before the given unit.boolean
isNeverNullBefore(soot.Local local, soot.Unit unit)
Return the set of other fields and locals that must reference the same object as the given local, at a point before the given unit.-
Methods inherited from class soot.jimple.toolkits.annotation.nullcheck.BranchedRefVarsAnalysis
anyRefInfo, copy, entryInitialFlow, flowThrough, getEquivalentValue, getKRefIntPair, isAlwaysNonNull, merge, newInitialFlow, refInfo, refInfo, treatTrapHandlersAsEntries
-
-
-
-
Method Detail
-
isAlwaysNullBefore
public boolean isAlwaysNullBefore(soot.Local local, soot.Unit unit)
Return the set of other fields and locals that must reference the same object as the given field, at a point before the given unit.
-
isNeverNullBefore
public boolean isNeverNullBefore(soot.Local local, soot.Unit unit)
Return the set of other fields and locals that must reference the same object as the given local, at a point before the given unit.
-
-