Class ScriptUseProvider
java.lang.Object
org.apache.sling.scripting.sightly.impl.engine.extension.use.ScriptUseProvider
- All Implemented Interfaces:
org.apache.sling.scripting.sightly.use.UseProvider
public class ScriptUseProvider
extends Object
implements org.apache.sling.scripting.sightly.use.UseProvider
Use provider that interprets the identifier as a script path, and runs the respective script using a script engine that matches the
script extension.
This provider returns a non-failure outcome only if the evaluated script actually returns something. For more details check the
implementation of the SlingScript.eval(SlingBindings)
method for the available script engines from your platform.
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionScriptUseProvider
(org.osgi.framework.BundleContext bundleContext, BundledUnitManagerImpl bundledUnitManager, ScriptDependencyResolver scriptDependencyResolver) -
Method Summary
-
Field Details
-
scriptDependencyResolver
-
-
Constructor Details
-
ScriptUseProvider
public ScriptUseProvider(org.osgi.framework.BundleContext bundleContext, BundledUnitManagerImpl bundledUnitManager, ScriptDependencyResolver scriptDependencyResolver)
-
-
Method Details
-
deactivate
protected void deactivate() -
provide
public org.apache.sling.scripting.sightly.use.ProviderOutcome provide(String scriptName, org.apache.sling.scripting.sightly.render.RenderContext renderContext, Bindings arguments) - Specified by:
provide
in interfaceorg.apache.sling.scripting.sightly.use.UseProvider
-