ScriptUtils

Utility object providing extension functions for ScriptEngine.

Properties

Link copied to clipboard

Returns the engine-scope Bindings for this ScriptEngine.

Link copied to clipboard

Returns the global-scope Bindings for this ScriptEngine.

Functions

Link copied to clipboard
fun ScriptEngine.bindings(scope: Int = ENGINE_SCOPE): Bindings

Returns the Bindings for the specified scope on this ScriptEngine.

Link copied to clipboard
fun ScriptEngine.resetContext(nullGlobalContext: Boolean = false)

Resets the context of this ScriptEngine by creating a new SimpleScriptContext with fresh bindings.