Class RhinoEngine
java.lang.Object
com.adobe.xfa.scripthandler.rhino.RhinoEngine
A class to access instances of the Rhino JavaScript engine.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic void
destroy()
Destroys the Rhino engine.static Context
Creates a Javascript Context which is thread local.static Scriptable
Gets this engine's top level scope.static void
setTopLevelScope
(ScriptableObject scriptableObject) Sets the top level scope from the given global object.
-
Constructor Details
-
RhinoEngine
public RhinoEngine()
-
-
Method Details
-
getThreadLocalRuntimeContext
Creates a Javascript Context which is thread local. It also:- disables Rhino's LiveConnect feature,
- sets the desired JavaScript language.
-
destroy
public static void destroy()Destroys the Rhino engine. -
getTopLevelScope
Gets this engine's top level scope.- Returns:
- the Rhino engine's top level scope object.
-
setTopLevelScope
Sets the top level scope from the given global object.- Parameters:
scriptableObject
- a scriptable object. This object is registered as a global object, with all other JavaScript global objects.
-