org.codehaus.plexus.util.cli
public abstract class CommandLineUtils extends Object
Version: $Id: CommandLineUtils.java 3038 2006-02-11 13:51:19Z evenisse $
Nested Class Summary | |
---|---|
static class | CommandLineUtils.StringStreamConsumer |
Field Summary | |
---|---|
static Map | processes |
Method Summary | |
---|---|
static int | executeCommandLine(Commandline cl, StreamConsumer systemOut, StreamConsumer systemErr) |
static int | executeCommandLine(Commandline cl, InputStream systemIn, StreamConsumer systemOut, StreamConsumer systemErr) |
static Properties | getSystemEnvVars() |
static boolean | isAlive(long pid) |
static void | killProcess(long pid)
Kill a process launched by executeCommandLine methods
Doesn't work correctly on windows, only the cmd process will be destroy but not the sub process (
Methods inherited from class java.util.AbstractCollection
addAll
contains
Methods inherited from class java.lang.Object clone finalize Methods inherited from interface java.util.List addAll contains -->Field Detailprocessesprivate static Map processes
Method DetailexecuteCommandLinepublic static int executeCommandLine(Commandline cl, StreamConsumer systemOut, StreamConsumer systemErr)
executeCommandLinepublic static int executeCommandLine(Commandline cl, InputStream systemIn, StreamConsumer systemOut, StreamConsumer systemErr)
getSystemEnvVarspublic static Properties getSystemEnvVars()
isAlivepublic static boolean isAlive(long pid)
killProcesspublic static void killProcess(long pid)
Kill a process launched by executeCommandLine methods
Doesn't work correctly on windows, only the cmd process will be destroy but not the sub process (Bug ID 4770092)
Parameters: pid The pid of command return by Commandline.getPid() |