| java.lang.Object com.ivata.groupware.admin.script.ExternalScriptExecutor
ExternalScriptExecutor | public class ExternalScriptExecutor implements ScriptExecutor(Code) | | Simple class to let you run scripts which exist outside the JVM world.
author: Colin MacLeod author: colin.macleod@ivata.com since: Apr 6, 2004 version: $Revision: 1.5 $ |
Constructor Summary | |
public | ExternalScriptExecutor(URLFormat uRLFormatParam, String scriptPathParam, String environmentVariablesParam)
Construct a script executor to execute external scripts. |
Method Summary | |
public String | exec(String scriptName, String[] arguments) Execute a command and handle any error that occurs.
Parameters: scriptName - name of the script to be executed. Parameters: arguments - command name and all arguments of to be executed. |
ExternalScriptExecutor | public ExternalScriptExecutor(URLFormat uRLFormatParam, String scriptPathParam, String environmentVariablesParam)(Code) | |
Construct a script executor to execute external scripts.
Parameters: scriptPathParam - full path to the location where the scripts arestored for this executor. Parameters: environmentVariablesParam - all environment variables to be set inthe script environemnt, separated by line feeds. Parameters: uRLFormatParam - used to format variables to avoid problems withcommand line spaces. |
exec | public String exec(String scriptName, String[] arguments) throws SystemException(Code) | | Execute a command and handle any error that occurs.
Parameters: scriptName - name of the script to be executed. Parameters: arguments - command name and all arguments of to be executed. Thefirst argument should always be the script name throws: SystemException - if the command returns non-zero, or if there isan input/output exception. all lines of the program output as a String . |
|
|