org.netbeans.api.extexecution
Class ExternalProcessSupport
java.lang.Object
org.netbeans.api.extexecution.ExternalProcessSupport
public final class ExternalProcessSupport
- extends Object
Utility class capable of properly terminating external process along with any
child processes created during execution.
- Since:
- 1.16
Method Summary |
static void |
destroy(Process process,
Map<String,String> env)
Destroys the process passed as parameter and attempts to terminate all child
processes created during the process' execution. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
destroy
public static void destroy(@NonNull
Process process,
@NonNull
Map<String,String> env)
- Destroys the process passed as parameter and attempts to terminate all child
processes created during the process' execution.
Any process running in environment containing the same variables
with the same values as those passed in env
(all of them)
is supposed to be part of the process tree and may be terminated.
- Parameters:
process
- process to killenv
- map containing the variables and their values which the
process must have to be considered being part of
the tree to kill