Interface ScriptTemplateConfig
- All Known Implementing Classes:
ScriptTemplateConfigurer
public interface ScriptTemplateConfig
Interface to be implemented by objects that configure and manage a
JSR-223
ScriptEngine
for automatic lookup in a web environment.
Detected and used by ScriptTemplateView
.- Since:
- 4.2
- Author:
- Sebastien Deleuze
-
Method Summary
Modifier and TypeMethodDescriptionReturn the charset used to read script and template files.Return the content type to use for the response.Return theScriptEngine
to use by the views.Return the engine name that will be used to instantiate theScriptEngine
.Return the engine supplier that will be used to instantiate theScriptEngine
.Return the render function name (optional).Return the object where the render function belongs (optional).Return the resource loader path(s) via a Spring resource location.String[]
Return the scripts to be loaded by the script engine (library or user provided).Return whether to use a shared engine for all threads or whether to create thread-local engine instances for each thread.
-
Method Details
-
getEngine
Return theScriptEngine
to use by the views. -
getEngineSupplier
Return the engine supplier that will be used to instantiate theScriptEngine
.- Since:
- 5.2
-
getEngineName
Return the engine name that will be used to instantiate theScriptEngine
. -
getScripts
Return the scripts to be loaded by the script engine (library or user provided). -
getRenderObject
Return the object where the render function belongs (optional). -
getRenderFunction
Return the render function name (optional). If not specified, the script templates will be evaluated withScriptEngine.eval(String, Bindings)
. -
getContentType
Return the content type to use for the response.- Since:
- 4.2.1
-
getCharset
Return the charset used to read script and template files. -
getResourceLoaderPath
Return the resource loader path(s) via a Spring resource location.
-