public class GroovyEngine
extends org.apache.bsf.util.BSFEngineImpl
It's derived from the Jython / JPython engine
Modifier and Type | Field and Description |
---|---|
protected GroovyShell |
shell |
Constructor and Description |
---|
GroovyEngine() |
Modifier and Type | Method and Description |
---|---|
java.lang.Object |
apply(java.lang.String source,
int lineNo,
int columnNo,
java.lang.Object funcBody,
java.util.Vector paramNames,
java.util.Vector arguments)
Allow an anonymous function to be declared and invoked
|
java.lang.Object |
call(java.lang.Object object,
java.lang.String method,
java.lang.Object[] args)
Call the named method of the given object.
|
void |
declareBean(org.apache.bsf.BSFDeclaredBean bean)
Declare a bean
|
java.lang.Object |
eval(java.lang.String source,
int lineNo,
int columnNo,
java.lang.Object script)
Evaluate an expression.
|
void |
exec(java.lang.String source,
int lineNo,
int columnNo,
java.lang.Object script)
Execute a script.
|
protected GroovyShell |
getEvalShell() |
void |
initialize(org.apache.bsf.BSFManager mgr,
java.lang.String lang,
java.util.Vector declaredBeans)
Initialize the engine.
|
void |
undeclareBean(org.apache.bsf.BSFDeclaredBean bean)
Undeclare a previously declared bean.
|
protected GroovyShell shell
public java.lang.Object apply(java.lang.String source, int lineNo, int columnNo, java.lang.Object funcBody, java.util.Vector paramNames, java.util.Vector arguments) throws org.apache.bsf.BSFException
apply
in interface org.apache.bsf.BSFEngine
apply
in class org.apache.bsf.util.BSFEngineImpl
org.apache.bsf.BSFException
public java.lang.Object call(java.lang.Object object, java.lang.String method, java.lang.Object[] args) throws org.apache.bsf.BSFException
org.apache.bsf.BSFException
public java.lang.Object eval(java.lang.String source, int lineNo, int columnNo, java.lang.Object script) throws org.apache.bsf.BSFException
org.apache.bsf.BSFException
public void exec(java.lang.String source, int lineNo, int columnNo, java.lang.Object script) throws org.apache.bsf.BSFException
exec
in interface org.apache.bsf.BSFEngine
exec
in class org.apache.bsf.util.BSFEngineImpl
org.apache.bsf.BSFException
public void initialize(org.apache.bsf.BSFManager mgr, java.lang.String lang, java.util.Vector declaredBeans) throws org.apache.bsf.BSFException
initialize
in interface org.apache.bsf.BSFEngine
initialize
in class org.apache.bsf.util.BSFEngineImpl
org.apache.bsf.BSFException
public void declareBean(org.apache.bsf.BSFDeclaredBean bean) throws org.apache.bsf.BSFException
declareBean
in interface org.apache.bsf.BSFEngine
declareBean
in class org.apache.bsf.util.BSFEngineImpl
org.apache.bsf.BSFException
public void undeclareBean(org.apache.bsf.BSFDeclaredBean bean) throws org.apache.bsf.BSFException
undeclareBean
in interface org.apache.bsf.BSFEngine
undeclareBean
in class org.apache.bsf.util.BSFEngineImpl
org.apache.bsf.BSFException
protected GroovyShell getEvalShell()