Actual Duplicate: How to stop a maven project started in Netbeans (That's mine after I figured out how to solve it properly)
My initial problem is that I want to detect a program stop from Netbeans. That doesn't work with the expected functions, not with Shudtdown Hooks or finalizer (compare).
The only difference I've noticed is that when I hit the stop button in Netbeans, the output window doesn't display the output of the program anymore. So I assume that the Reader for the Standard Out disconnected.
Therefore I want to notice the situation where there is nowhere the text is going.
I fear "No" is the answer as I could not find anything about it.
I tried the solutions in Shutdown hook doesn't work in Eclipse but they don't work. NetBeans doesn't have a process that I could override (except of course by changing the NetBeans code) and the System Property that is set by Eclipse is (obviously) not set in Netbeans. Also, I have no input into the Netbeans console, so that won't work either.
I should have mentioned that its a maven project, that could change some things.