org.eclipse.rse.subsystems.shells.core.model
Class SimpleCommandOperation
java.lang.Object
org.eclipse.rse.subsystems.shells.core.model.SimpleCommandOperation
public class SimpleCommandOperation
- extends Object
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
_subsystem
protected IRemoteCmdSubSystem _subsystem
_workingDirectory
protected IRemoteFile _workingDirectory
_cmdShell
protected IRemoteCommandShell _cmdShell
_envVars
protected List _envVars
_outputLineIndex
protected int _outputLineIndex
_runAsShell
protected boolean _runAsShell
SimpleCommandOperation
public SimpleCommandOperation(IRemoteCmdSubSystem subsystem,
IRemoteFile workingDirectory,
boolean runAsShell)
getCommandShell
public IRemoteCommandShell getCommandShell()
setEnvironmentVariable
public void setEnvironmentVariable(String name,
String value)
setEnvironmentVariables
public void setEnvironmentVariables(String[] names,
String[] values)
setEnvironmentVariables
public void setEnvironmentVariables(String[] vars)
getEnvironmentVariables
public String[] getEnvironmentVariables()
runCommand
public void runCommand(String command,
boolean exitShell)
throws Exception
- Run a command
- Parameters:
command
- the command to runexitShell
- indicates whether to exit the shell after running the command
- Throws:
Exception
runCommandInShell
public void runCommandInShell(String exports,
String command,
boolean exitShell)
throws Exception
- Launch a shell with the specified exports and command
- Parameters:
exports
- the command to initialize the shell environmentcommand
- the command to runexitShell
- indicates whether to exit the shell after running the command
- Throws:
Exception
removeShell
public void removeShell()
exitShell
public void exitShell()
putInput
public void putInput(String input)
throws Exception
- Throws:
Exception
isActive
public boolean isActive()
hasMoreOutput
protected boolean hasMoreOutput()
cancelCommand
public void cancelCommand()
throws Exception
- Throws:
Exception
readLine
public String readLine(boolean waitForOutput)
Copyright (c) IBM Corporation and others 2000, 2011. All Rights Reserved.