public class QLExpressScriptEngine extends AbstractScriptEngine
contextARGV, ENGINE, ENGINE_VERSION, FILENAME, LANGUAGE, LANGUAGE_VERSION, NAME| 构造器和说明 |
|---|
QLExpressScriptEngine(QLExpressScriptEngineFactory factory)
Creates a new instance of AbstractScriptEngine using a
SimpleScriptContext
as its default ScriptContext. |
| 限定符和类型 | 方法和说明 |
|---|---|
Bindings |
createBindings()
Returns an uninitialized
Bindings. |
Object |
eval(Reader reader,
ScriptContext context)
Same as
eval(String, ScriptContext) where the source of the script
is read from a Reader. |
Object |
eval(String script,
ScriptContext context)
Causes the immediate execution of the script whose source is the String
passed as the first argument.
|
ScriptEngineFactory |
getFactory()
Returns a
ScriptEngineFactory for the class to which this ScriptEngine belongs. |
com.ql.util.express.ExpressRunner |
getRunner() |
eval, eval, eval, eval, get, getBindings, getContext, getScriptContext, put, setBindings, setContextpublic QLExpressScriptEngine(QLExpressScriptEngineFactory factory)
SimpleScriptContext
as its default ScriptContext.public Object eval(String script, ScriptContext context) throws ScriptException
script - The script to be executed by the script engine.context - A ScriptContext exposing sets of attributes in
different scopes. The meanings of the scopes ScriptContext.GLOBAL_SCOPE,
and ScriptContext.ENGINE_SCOPE are defined in the specification.
ENGINE_SCOPE Bindings of the ScriptContext contains the
bindings of scripting variables to application objects to be used during this
script execution.ScriptException - if an error occurs in script. ScriptEngines should create and throw
ScriptException wrappers for checked Exceptions thrown by underlying scripting
implementations.NullPointerException - if either argument is null.public Object eval(Reader reader, ScriptContext context) throws ScriptException
eval(String, ScriptContext) where the source of the script
is read from a Reader.reader - The source of the script to be executed by the script engine.context - The ScriptContext passed to the script engine.ScriptException - if an error occurs in script.NullPointerException - if either argument is null.public Bindings createBindings()
Bindings.Bindings that can be used to replace the state of this ScriptEngine.public ScriptEngineFactory getFactory()
ScriptEngineFactory for the class to which this ScriptEngine belongs.ScriptEngineFactorypublic com.ql.util.express.ExpressRunner getRunner()
Copyright © 2023. All rights reserved.