Process.kill

Kill a running process. This method will not return until the process has been killed.

class Process
void
kill
()

Throws

ProcessKillException if the process could not be killed; ProcessWaitException if we could not wait on the process after killing it.

Remarks: After calling this method you will not be able to call wait() on the process. Killing the process does not clean the attached pipes as the parent process may still want/need the remaining content. However, it is recommended to call close() on the process when it is no longer needed as this will clean the pipes.

Meta