public class RhinoScriptEngine extends AbstractScriptEngine
Modifier and Type | Field and Description |
---|---|
static String |
ENGINE_ID |
ASYNC_FINISH, BUILD, DECORATE, INTERACTIVE, LONG, NONE, RUNNING, SHORT, SLEEPING, WAITING
TRACE_SCRIPT_ENGINE
Constructor and Description |
---|
RhinoScriptEngine()
Creates a new Rhino interpreter.
|
Modifier and Type | Method and Description |
---|---|
org.mozilla.javascript.Context |
getContext() |
String |
getSaveVariableName(String name)
Return a save name to be used for a variable.
|
static Object |
getVariable(org.mozilla.javascript.Scriptable scope,
String name) |
static Map<String,Object> |
getVariables(org.mozilla.javascript.Scriptable scope) |
void |
registerJar(URL url)
Register a jar file and add it to the classpath.
|
void |
setDebugger(org.mozilla.javascript.debug.Debugger debugger) |
void |
setOptimizationLevel(int level) |
void |
terminateCurrent()
Stops the currently executed piece of code.
|
addExecutionListener, addSecurityCheck, executeAsync, executeSync, extractArguments, getDescription, getErrorStream, getExecutedFile, getInputStream, getOutputStream, getStackTrace, getTerminateOnIdle, getVariable, getVariables, hasVariable, inject, injectUI, isFinished, isIdle, join, removeExecutionListener, removeSecurityCheck, removeVariable, setCloseStreamsOnTerminate, setEngineDescription, setErrorStream, setInputStream, setOutputStream, setTerminateOnIdle, setVariable, terminate
addJobChangeListener, belongsTo, cancel, create, create, createSystem, createSystem, done, getJobGroup, getJobManager, getName, getPriority, getProperty, getResult, getRule, getState, getThread, isBlocking, isSystem, isUser, join, join, removeJobChangeListener, schedule, schedule, setJobGroup, setName, setPriority, setProgressGroup, setProperty, setRule, setSystem, setThread, setUser, shouldRun, shouldSchedule, sleep, toString, wakeUp, wakeUp, yieldRule
getAdapter
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
getName, schedule
getAdapter
public static final String ENGINE_ID
public void setOptimizationLevel(int level)
public org.mozilla.javascript.Context getContext()
public void terminateCurrent()
IScriptEngine
public void setDebugger(org.mozilla.javascript.debug.Debugger debugger)
public void registerJar(URL url)
IScriptEngine
url
- url to load jar file frompublic String getSaveVariableName(String name)
IScriptEngine
name
- variable name candidate