terminating the program from the terminate button of the eclipse console is equivalent to kill it by using a task manager. It's not safe to edit the command on the red terminate button, but you can make the program to do things before exiting shutdown hook
Handle the click on the Terminate button of an Eclipse's console?
-
29-09-2022 - |
質問
Using Eclipse, I'm launching an external program through an "External Tool Configuration".
My program has a "bin/launch-program" executable, but also a "bin/stop-program" which is the only way to stop the program.
In my Eclipse's External Tool Configuration, tab "Main", I set:
- Location: <PROGRAM_HOME>/bin/launch-program
- Working Directory: <PROGRAM_HOME>
But I'm looking a way to handle the stop event.
In other words, launching an external program works well: I get the output in the Eclipse's console. The question is: how to handle the click on the Terminate button of the console, to launch a specific command line?
解決
所属していません StackOverflow