|
Groovy Documentation | |||||||
FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.codehaus.groovy.ast.CodeVisitorSupport org.codehaus.groovy.ast.ClassCodeVisitorSupport org.codehaus.groovy.transform.AbstractInterruptibleASTTransformation org.codehaus.groovy.transform.ThreadInterruptibleASTTransformation
@GroovyASTTransformation(phase = CompilePhase.CANONICALIZATION) class ThreadInterruptibleASTTransformation extends AbstractInterruptibleASTTransformation
Allows "interrupt-safe" executions of scripts by adding Thread.currentThread().isInterrupted() checks on loops (for, while, do) and first statement of closures. By default, also adds an interrupt check statement on the beginning of method calls.
Field Summary |
---|
Method Summary | |
---|---|
protected Expression
|
createCondition()
|
protected java.lang.String
|
getErrorMessage()
|
protected ClassNode
|
type()
|
void
|
visitClosureExpression(ClosureExpression closureExpr)
|
void
|
visitMethod(MethodNode node)
|
Methods inherited from class java.lang.Object | |
---|---|
java.lang.Object#wait(long), java.lang.Object#wait(long, int), java.lang.Object#wait(), java.lang.Object#equals(java.lang.Object), java.lang.Object#toString(), java.lang.Object#hashCode(), java.lang.Object#getClass(), java.lang.Object#notify(), java.lang.Object#notifyAll() |
Method Detail |
---|
protected Expression createCondition()
protected java.lang.String getErrorMessage()
protected ClassNode type()
@Override void visitClosureExpression(ClosureExpression closureExpr)
@Override void visitMethod(MethodNode node)
Groovy Documentation