View Javadoc
1   package org.codehaus.plexus.util.cli;
2   
3   public class ProcessHook extends Thread {
4   
5   	private final Process process;
6   
7   	public ProcessHook(Process process) {
8   		super("CommandlineUtils process shutdown hook");
9   		this.process = process;
10  		this.setContextClassLoader(null);
11  	}
12  
13  	@Override
14  	public void run() {
15  		process.destroy();
16  	}
17  }