TimedInterrupt annotation for executing scripts with GroovyShell
I tried o use @TimeInterrupt annotation with GroovyLab,
in order to interrupt scripts that take much time.
I implemented a TimedInterrupt mode,
in which GroovyLab inserts the line
before each script
and then passes the script to the GroovyShell for evaluate().
The timed interrupt works but unfortunately the binding of variables
fails to work properly.
I suspect that the TimedInterrupt annotation should be placed,
before the method run() of the script,
so a possible solution is to intervene at the Groovy's source code,
however that is not elegant,
since it requires compiling Groovy's source with GroovyLab.