edu.rice.cs.dynamicjava.interpreter
Class TryBlockContext

java.lang.Object
  extended by edu.rice.cs.dynamicjava.interpreter.DelegatingContext
      extended by edu.rice.cs.dynamicjava.interpreter.TryBlockContext
All Implemented Interfaces:
TypeContext

public class TryBlockContext
extends DelegatingContext

A block in which additional exception types are allowed to be thrown.


Constructor Summary
TryBlockContext(TypeContext next, java.lang.Iterable<Type> caughtTypes)
           
 
Method Summary
protected  TryBlockContext duplicate(TypeContext next)
          Create a copy of this context with the given context enclosing it.
 java.lang.Iterable<Type> getDeclaredThrownTypes()
          The types that are allowed to be thrown in the current context.
 
Methods inherited from class edu.rice.cs.dynamicjava.interpreter.DelegatingContext
accessModule, fieldExists, functionExists, getClassLoader, getLocalFunctions, getLocalFunctions, getLocalVariable, getReturnType, getThis, getThis, getThis, getTopLevelClass, getTypeVariable, importField, importMemberClass, importMemberClasses, importMethod, importStaticMembers, importTopLevelClass, importTopLevelClasses, initializingClass, localFunctionExists, localVariableExists, makeAnonymousClassName, makeClassName, memberClassExists, methodExists, setPackage, topLevelClassExists, typeContainingField, typeContainingMemberClass, typeContainingMethod, typeExists, typeVariableExists, variableExists
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TryBlockContext

public TryBlockContext(TypeContext next,
                       java.lang.Iterable<Type> caughtTypes)
Method Detail

duplicate

protected TryBlockContext duplicate(TypeContext next)
Description copied from class: DelegatingContext
Create a copy of this context with the given context enclosing it.

Specified by:
duplicate in class DelegatingContext

getDeclaredThrownTypes

public java.lang.Iterable<Type> getDeclaredThrownTypes()
The types that are allowed to be thrown in the current context. If there is no such declaration, the list will be empty.

Specified by:
getDeclaredThrownTypes in interface TypeContext
Overrides:
getDeclaredThrownTypes in class DelegatingContext