at.dms.kjc
Class CThrowableInfo

java.lang.Object
  |
  +--at.dms.util.Utils
        |
        +--at.dms.kjc.CThrowableInfo

public class CThrowableInfo
extends Utils

This class represents a throw information during check.


Fields inherited from class at.dms.util.Utils
DBG_LEVEL_HIGH, DBG_LEVEL_LOW, DBG_LEVEL_NO
 
Constructor Summary
CThrowableInfo(CClassType throwable, JPhylum location, CBodyContext context, boolean subTypePossible)
          Constructs a throwable-information handler.
 
Method Summary
 boolean equals(java.lang.Object o)
           
 CBodyContext getContext()
          Return the context where this throw occurs.
 JPhylum getLocation()
          Return the location of this throwable.
 CClassType getThrowable()
          Returns the type of exception.
 int hashCode()
           
 boolean isCaught()
          Return true if this throwable is caught.
 boolean isSubTypePossible()
          Returns whether subTypes are possible for this throwable, or whether the property throwable is exactly the type that can be thrown.
 void setCaught(boolean caught)
          Sets this throwable to be cached or not.
 
Methods inherited from class at.dms.util.Utils
assert, assert, fail, fail, hasFlag, hasMoreThanOneFlag, hasOtherFlags, splitQualifiedName, splitQualifiedName, vectorToArray, vectorToIntArray
 
Methods inherited from class java.lang.Object
, clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CThrowableInfo

public CThrowableInfo(CClassType throwable,
                      JPhylum location,
                      CBodyContext context,
                      boolean subTypePossible)
Constructs a throwable-information handler.
Parameters:
throwable - The type of exception.
location - The throw statement.
context - The state of control flow at throw time.
Method Detail

isSubTypePossible

public boolean isSubTypePossible()
Returns whether subTypes are possible for this throwable, or whether the property throwable is exactly the type that can be thrown. This is necessary for reachability checking.

getThrowable

public CClassType getThrowable()
Returns the type of exception.

getLocation

public JPhylum getLocation()
Return the location of this throwable.

getContext

public CBodyContext getContext()
Return the context where this throw occurs.

setCaught

public void setCaught(boolean caught)
Sets this throwable to be cached or not.

isCaught

public boolean isCaught()
Return true if this throwable is caught.

equals

public boolean equals(java.lang.Object o)
Overrides:
equals in class java.lang.Object

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object