public abstract class StandardScriptUtils
extends java.lang.Object
ScriptEngine
.Constructor and Description |
---|
StandardScriptUtils() |
Modifier and Type | Method and Description |
---|---|
static javax.script.ScriptEngine |
retrieveEngineByName(javax.script.ScriptEngineManager scriptEngineManager,
java.lang.String engineName)
Retrieve a
ScriptEngine from the given ScriptEngineManager
by name, delegating to ScriptEngineManager.getEngineByName(java.lang.String) but
throwing a descriptive exception if not found or if initialization failed. |
public static javax.script.ScriptEngine retrieveEngineByName(javax.script.ScriptEngineManager scriptEngineManager, java.lang.String engineName)
ScriptEngine
from the given ScriptEngineManager
by name, delegating to ScriptEngineManager.getEngineByName(java.lang.String)
but
throwing a descriptive exception if not found or if initialization failed.scriptEngineManager
- the ScriptEngineManager to useengineName
- the name of the enginenull
)java.lang.IllegalArgumentException
- if no matching engine has been foundjava.lang.IllegalStateException
- if the desired engine failed to initialize