soot.toolkits.exceptions
Class AbstractThrowAnalysis

java.lang.Object
  extended by soot.toolkits.exceptions.AbstractThrowAnalysis
All Implemented Interfaces:
ThrowAnalysis
Direct Known Subclasses:
PedanticThrowAnalysis, UnitThrowAnalysis

public abstract class AbstractThrowAnalysis
extends Object
implements ThrowAnalysis

Abstract class implementing parts of the ThrowAnalysis interface which may be common to multiple concrete ThrowAnalysis classes. AbstractThrowAnalysis provides straightforward implementations of mightThrowExplicitly(ThrowInst) and mightThrowExplicitly(ThrowStmt), since concrete implementations of ThrowAnalysis seem likely to differ mainly in their treatment of implicit exceptions.


Constructor Summary
AbstractThrowAnalysis()
           
 
Method Summary
abstract  ThrowableSet mightThrow(Unit u)
          Returns a set representing the Throwable types that the specified unit might throw.
 ThrowableSet mightThrowExplicitly(ThrowInst t)
          Returns a set representing the Throwable types that the specified throw instruction might throw explicitly, that is, the possible types for its Throwable argument.
 ThrowableSet mightThrowExplicitly(ThrowStmt t)
          Returns a set representing the Throwable types that the specified throw statement might throw explicitly, that is, the possible types for its Throwable argument.
abstract  ThrowableSet mightThrowImplicitly(ThrowInst t)
          Returns a set representing the Throwable types that the specified throw instruction might throw implicitly, that is, the possible types of errors which might arise in the course of executing the throw instruction, rather than the type of the throw's operand.
abstract  ThrowableSet mightThrowImplicitly(ThrowStmt t)
          Returns a set representing the Throwable types that the specified throw statement might throw implicitly, that is, the possible types of errors which might arise in the course of executing the throw statement, rather than the type of the throw's operand.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AbstractThrowAnalysis

public AbstractThrowAnalysis()
Method Detail

mightThrow

public abstract ThrowableSet mightThrow(Unit u)
Description copied from interface: ThrowAnalysis
Returns a set representing the Throwable types that the specified unit might throw.

Specified by:
mightThrow in interface ThrowAnalysis
Parameters:
u - Unit whose exceptions are to be returned.
Returns:
a representation of the Throwable types that u might throw.

mightThrowExplicitly

public ThrowableSet mightThrowExplicitly(ThrowInst t)
Description copied from interface: ThrowAnalysis
Returns a set representing the Throwable types that the specified throw instruction might throw explicitly, that is, the possible types for its Throwable argument.

Specified by:
mightThrowExplicitly in interface ThrowAnalysis
Parameters:
t - ThrowInst whose explicit exceptions are to be returned.
Returns:
a representation of the possible types of t's Throwable operand.

mightThrowExplicitly

public ThrowableSet mightThrowExplicitly(ThrowStmt t)
Description copied from interface: ThrowAnalysis
Returns a set representing the Throwable types that the specified throw statement might throw explicitly, that is, the possible types for its Throwable argument.

Specified by:
mightThrowExplicitly in interface ThrowAnalysis
Parameters:
t - ThrowStmt whose explicit exceptions are to be returned.
Returns:
a representation of the possible types of t's Throwable operand.

mightThrowImplicitly

public abstract ThrowableSet mightThrowImplicitly(ThrowInst t)
Description copied from interface: ThrowAnalysis
Returns a set representing the Throwable types that the specified throw instruction might throw implicitly, that is, the possible types of errors which might arise in the course of executing the throw instruction, rather than the type of the throw's operand.

Specified by:
mightThrowImplicitly in interface ThrowAnalysis
Parameters:
t - ThrowStmt whose implicit exceptions are to be returned.
Returns:
a representation of the types of exceptions that t might throw implicitly.

mightThrowImplicitly

public abstract ThrowableSet mightThrowImplicitly(ThrowStmt t)
Description copied from interface: ThrowAnalysis
Returns a set representing the Throwable types that the specified throw statement might throw implicitly, that is, the possible types of errors which might arise in the course of executing the throw statement, rather than the type of the throw's operand.

Specified by:
mightThrowImplicitly in interface ThrowAnalysis
Parameters:
t - ThrowStmt whose implicit exceptions are to be returned.
Returns:
a representation of the types of exceptions that t might throw implicitly.