Package org.junit.jupiter.engine.script
Class ScriptExecutionManager
- java.lang.Object
-
- org.junit.jupiter.engine.script.ScriptExecutionManager
-
- All Implemented Interfaces:
ExtensionContext.Store.CloseableResource
@API(status=INTERNAL, since="5.1") public class ScriptExecutionManager extends java.lang.Object implements ExtensionContext.Store.CloseableResource
Entry point for script execution support.- Since:
- 5.1
-
-
Constructor Summary
Constructors Constructor Description ScriptExecutionManager()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidclose()Close underlying resources.java.lang.Objectevaluate(Script script, javax.script.Bindings bindings)Evaluate the script using the given bindings.
-
-
-
Method Detail
-
close
public void close()
Description copied from interface:ExtensionContext.Store.CloseableResourceClose underlying resources.- Specified by:
closein interfaceExtensionContext.Store.CloseableResource
-
evaluate
public java.lang.Object evaluate(Script script, javax.script.Bindings bindings) throws javax.script.ScriptException
Evaluate the script using the given bindings.- Parameters:
script- the script to evaluatebindings- the context-aware bindings- Returns:
- the result object
- Throws:
javax.script.ScriptException- if an error occurs in script.
-
-