org.apache.maven.it.util.cli.shell
public class Shell extends java.lang.Object
Class that abstracts the Shell functionality, with subclases for shells that behave particularly, like
command.com
cmd.exe
Constructor and Description |
---|
Shell() |
Modifier and Type | Method and Description |
---|---|
java.util.List |
getCommandLine(java.lang.String executable,
java.lang.String[] arguments)
Get the command line for the provided executable and arguments in this shell
|
java.lang.String[] |
getShellArgs()
Get the shell arguments
|
java.lang.String |
getShellCommand()
Get the command to execute the shell
|
java.util.List |
getShellCommandLine(java.lang.String executable,
java.lang.String[] arguments)
Get the full command line to execute, including shell command, shell arguments,
executable and executable arguments
|
void |
setShellArgs(java.lang.String[] shellArgs)
Set the shell arguments when calling a command line (not the executable arguments)
(eg.
|
void |
setShellCommand(java.lang.String shellCommand)
Set the command to execute the shell (eg.
|
public void setShellCommand(java.lang.String shellCommand)
shellCommand
- public java.lang.String getShellCommand()
public void setShellArgs(java.lang.String[] shellArgs)
shellArgs
- public java.lang.String[] getShellArgs()
public java.util.List getCommandLine(java.lang.String executable, java.lang.String[] arguments)
executable
- executable that the shell has to callarguments
- arguments for the executable, not the shellpublic java.util.List getShellCommandLine(java.lang.String executable, java.lang.String[] arguments)
executable
- executable that the shell has to callarguments
- arguments for the executable, not the shellCopyright © 2014. All Rights Reserved.