/**
  * Parses the argument text into an array of individual strings using the space character as the
  * delimiter. An individual argument containing spaces must have a double quote (") at the start
  * and end. Two double quotes together is taken to mean an embedded double quote in the argument
  * text.
  *
  * @param arguments the arguments as one string
  * @return the array of arguments
  */
 public static String[] parseStringIntoList(String arguments) {
   return ProcessUtils.parseArguments(arguments);
 }
Exemple #2
0
 /**
  * @param process process from where the output should be gotten
  * @param executionString string to execute (only for errors)
  * @param monitor monitor for giving progress
  * @return a tuple with the output of stdout and stderr
  */
 public static Tuple<String, String> getProcessOutput(
     Process process, String executionString, IProgressMonitor monitor, String encoding) {
   return ProcessUtils.getProcessOutput(process, executionString, monitor, encoding);
 }
Exemple #3
0
 /** Passes the commands directly to Runtime.exec (with the passed envp) */
 public static Process createProcess(String[] cmdarray, String[] envp, File workingDir)
     throws IOException {
   return ProcessUtils.createProcess(cmdarray, envp, workingDir);
 }
Exemple #4
0
 /**
  * copied from org.eclipse.jdt.internal.launching.StandardVMRunner
  *
  * @param args - other arguments to be added to the command line (may be null)
  * @return
  */
 public static String getArgumentsAsStr(String[] commandLine, String... args) {
   return ProcessUtils.getArgumentsAsStr(commandLine, args);
 }