org.apache.sling.scripting.jst
Class JstScriptEngine

java.lang.Object
  extended by javax.script.AbstractScriptEngine
      extended by org.apache.sling.scripting.api.AbstractSlingScriptEngine
          extended by org.apache.sling.scripting.jst.JstScriptEngine
All Implemented Interfaces:
javax.script.ScriptEngine

public class JstScriptEngine
extends org.apache.sling.scripting.api.AbstractSlingScriptEngine

JST script engine. This engine does not really execute the supplied script: it dumps a default HTML representation of the current Resource, which includes a reference to the script path with a .jst.js selector and extension, so that the JsCodeGeneratorServlet can provide the template-specific client javascript code.


Field Summary
 
Fields inherited from class javax.script.AbstractScriptEngine
context
 
Fields inherited from interface javax.script.ScriptEngine
ARGV, ENGINE, ENGINE_VERSION, FILENAME, LANGUAGE, LANGUAGE_VERSION, NAME
 
Method Summary
 java.lang.Object eval(java.io.Reader script, javax.script.ScriptContext context)
          Output the HTML representation, with reference to the actual client-side script
 
Methods inherited from class org.apache.sling.scripting.api.AbstractSlingScriptEngine
createBindings, eval, getFactory
 
Methods inherited from class javax.script.AbstractScriptEngine
eval, eval, eval, eval, get, getBindings, getContext, getScriptContext, put, setBindings, setContext
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

eval

public java.lang.Object eval(java.io.Reader script,
                             javax.script.ScriptContext context)
                      throws javax.script.ScriptException
Output the HTML representation, with reference to the actual client-side script

Throws:
javax.script.ScriptException


Copyright © 2007-2012 The Apache Software Foundation. All Rights Reserved.