Class JavaxScriptRunner
- java.lang.Object
- 
- org.apache.tools.ant.util.ScriptRunnerBase
- 
- org.apache.tools.ant.util.optional.JavaxScriptRunner
 
 
- 
 public class JavaxScriptRunner extends ScriptRunnerBase This class is used to run scripts using JSR 223.- Since:
- Ant 1.7.0
 
- 
- 
Constructor SummaryConstructors Constructor Description JavaxScriptRunner()
 - 
Method SummaryModifier and Type Method Description java.lang.ObjectevaluateScript(java.lang.String execName)Do the work to eval the script.voidexecuteScript(java.lang.String execName)Do the work to run the script.java.lang.StringgetManagerName()Get the name of the manager prefix.booleansupportsLanguage()Check if a script engine can be created for this language.- 
Methods inherited from class org.apache.tools.ant.util.ScriptRunnerBaseaddBean, addBeans, addText, bindToComponent, bindToComponentMinimum, checkLanguage, clearScript, getBeans, getCompiled, getKeepEngine, getLanguage, getProject, getScript, getScriptClassLoader, loadResource, loadResources, replaceContextLoader, restoreContextLoader, setCompiled, setEncoding, setKeepEngine, setLanguage, setProject, setScriptClassLoader, setSrc
 
- 
 
- 
- 
- 
Method Detail- 
getManagerNamepublic java.lang.String getManagerName() Get the name of the manager prefix.- Specified by:
- getManagerNamein class- ScriptRunnerBase
- Returns:
- "javax"
 
 - 
supportsLanguagepublic boolean supportsLanguage() Check if a script engine can be created for this language..- Specified by:
- supportsLanguagein class- ScriptRunnerBase
- Returns:
- true if a script engine can be created, false otherwise.
 
 - 
executeScriptpublic void executeScript(java.lang.String execName) throws BuildExceptionDo the work to run the script.- Specified by:
- executeScriptin class- ScriptRunnerBase
- Parameters:
- execName- the name that will be passed to the scripting engine for this script execution.
- Throws:
- BuildException- if something goes wrong executing the script.
 
 - 
evaluateScriptpublic java.lang.Object evaluateScript(java.lang.String execName) throws BuildExceptionDo the work to eval the script.- Specified by:
- evaluateScriptin class- ScriptRunnerBase
- Parameters:
- execName- the name that will be passed to the scripting engine for this script execution.
- Returns:
- the result of the evaluation
- Throws:
- BuildException- if something goes wrong executing the script.
 
 
- 
 
-