public class ProxyEnv extends Object implements Env
| Modifier and Type | Method and Description |
|---|---|
void |
buildStackTraceElements(List<StackTraceElement> stack,
int depth)
Builds the current call stack information for
Throwable.getStackTrace(). |
Object |
closureOwner()
Closure or 'this' object that surrounds the currently executing code.
|
void |
declareVariable(Class type,
String name) |
Continuation |
getBreakAddress(String label)
If we see a break statement, where should we go?
|
Continuation |
getContinueAddress(String label)
If we see a continue statement, where should we go?
|
Continuation |
getExceptionHandler(Class<? extends Throwable> type)
Finds the exception handler that catches a
Throwable instance of this type. |
Invoker |
getInvoker()
Invoker is typically scoped at the whole execution. |
Object |
getLocalVariable(String name) |
Continuation |
getReturnAddress()
Where should the return statement return to?
|
void |
setLocalVariable(String name,
Object value) |
protected final Env parent
public ProxyEnv(Env parent)
public void declareVariable(Class type, String name)
declareVariable in interface Envpublic Object getLocalVariable(String name)
getLocalVariable in interface Envpublic void setLocalVariable(String name, Object value)
setLocalVariable in interface Envpublic Object closureOwner()
EnvclosureOwner in interface Envpublic Continuation getReturnAddress()
EnvgetReturnAddress in interface Envpublic Continuation getBreakAddress(String label)
EnvgetBreakAddress in interface Envlabel - Specifies the loop to break from. null for nearest loop.public Continuation getContinueAddress(String label)
EnvgetContinueAddress in interface Envlabel - Specifies the loop to repeat. null for nearest loop.public Continuation getExceptionHandler(Class<? extends Throwable> type)
EnvThrowable instance of this type.getExceptionHandler in interface Envpublic Invoker getInvoker()
EnvInvoker is typically scoped at the whole execution.getInvoker in interface Envpublic void buildStackTraceElements(List<StackTraceElement> stack, int depth)
EnvThrowable.getStackTrace().buildStackTraceElements in interface Envdepth - Maximum depth of stack trace to obtain.Copyright © 2011–2014. All rights reserved.